DPDK patches and discussions
 help / color / mirror / Atom feed
From: Rushil Gupta <rushilg@google.com>
To: Tathagat Priyadarshi <tathagat.dpdk@gmail.com>
Cc: dev@dpdk.org, Varun Lakkur Ambaji Rao <varun.la@gmail.com>
Subject: Re: [PATCH v3] net/gve: add support for TSO in DQO RDA
Date: Mon, 26 Aug 2024 20:11:27 -0700	[thread overview]
Message-ID: <CANzqiF4UkKN-NctuGU4e--EEoK16aU88EG4PFJamJ4cT_7_ocA@mail.gmail.com> (raw)
In-Reply-To: <1723229462-2439640-1-git-send-email-tathagat.dpdk@gmail.com>

Acked-by: Rushil Gupta <rushilg@google.com>

Thanks!


On Fri, Aug 9, 2024 at 11:49 AM Tathagat Priyadarshi
<tathagat.dpdk@gmail.com> wrote:
>
> The patch intends on adding support for TSO in DQO RDA format.
>
> Signed-off-by: Tathagat Priyadarshi <tathagat.dpdk@gmail.com>
> Signed-off-by: Varun Lakkur Ambaji Rao <varun.la@gmail.com>
> ---
>  drivers/net/gve/gve_tx_dqo.c | 26 +++++++++++++++++++++++---
>  1 file changed, 23 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/net/gve/gve_tx_dqo.c b/drivers/net/gve/gve_tx_dqo.c
> index b9d6d01..731c287 100644
> --- a/drivers/net/gve/gve_tx_dqo.c
> +++ b/drivers/net/gve/gve_tx_dqo.c
> @@ -72,6 +72,17 @@
>         txq->complq_tail = next;
>  }
>
I see that we are not populating the flex metadata here like the linux
driver. These metadata fields allow guest vm to send metadata to fxp.
However; that can be a separate change.


> +static inline void
> +gve_tx_fill_seg_desc_dqo(volatile union gve_tx_desc_dqo *desc, struct rte_mbuf *tx_pkt)
> +{
> +       uint32_t hlen = tx_pkt->l2_len + tx_pkt->l3_len + tx_pkt->l4_len;
> +       desc->tso_ctx.cmd_dtype.dtype = GVE_TX_TSO_CTX_DESC_DTYPE_DQO;
> +       desc->tso_ctx.cmd_dtype.tso = 1;
> +       desc->tso_ctx.mss = (uint16_t)tx_pkt->tso_segsz;
> +       desc->tso_ctx.tso_total_len = tx_pkt->pkt_len - hlen;
> +       desc->tso_ctx.header_len = (uint8_t)hlen;
> +}
> +
>  uint16_t
>  gve_tx_burst_dqo(void *tx_queue, struct rte_mbuf **tx_pkts, uint16_t nb_pkts)
>  {
> @@ -89,6 +100,7 @@
>         uint16_t sw_id;
>         uint64_t bytes;
>         uint16_t first_sw_id;
> +       uint8_t tso;
>         uint8_t csum;
>
>         sw_ring = txq->sw_ring;
> @@ -109,15 +121,23 @@
>                                 gve_tx_clean_dqo(txq);
>                 }
>
> -               if (txq->nb_free < tx_pkt->nb_segs)
> -                       break;
> -
>                 ol_flags = tx_pkt->ol_flags;
>                 nb_used = tx_pkt->nb_segs;
>                 first_sw_id = sw_id;
>
> +               tso = !!(ol_flags & RTE_MBUF_F_TX_TCP_SEG);
>                 csum = !!(ol_flags & GVE_TX_CKSUM_OFFLOAD_MASK_DQO);
>
> +               nb_used += tso;
> +               if (txq->nb_free < nb_used)
> +                       break;
> +
> +               if (tso) {
> +                       txd = &txr[tx_id];
> +                       gve_tx_fill_seg_desc_dqo(txd, tx_pkt);
> +                       tx_id = (tx_id + 1) & mask;
> +               }
> +
>                 do {
>                         if (sw_ring[sw_id] != NULL)
>                                 PMD_DRV_LOG(DEBUG, "Overwriting an entry in sw_ring");
> --
> 1.8.3.1
>

  parent reply	other threads:[~2024-08-27  3:11 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-08-01 10:19 [PATCH] net/gve: Add " Tathagat Priyadarshi
2024-08-01 10:33 ` Tathagat Priyadarshi
2024-08-07  9:40   ` Ferruh Yigit
2024-08-08 18:25     ` Tathagat Priyadarshi
2024-08-08 22:45       ` Ferruh Yigit
2024-08-09 18:51 ` [PATCH v3] net/gve: add " Tathagat Priyadarshi
2024-08-19 10:03   ` Tathagat Priyadarshi
2024-08-27  3:11   ` Rushil Gupta [this message]
2024-08-27 14:04     ` Ferruh Yigit

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CANzqiF4UkKN-NctuGU4e--EEoK16aU88EG4PFJamJ4cT_7_ocA@mail.gmail.com \
    --to=rushilg@google.com \
    --cc=dev@dpdk.org \
    --cc=tathagat.dpdk@gmail.com \
    --cc=varun.la@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).