From: Simon Horman <horms@kernel.org>
To: Dragos Tatulea <dtatulea@nvidia.com>
Cc: Tariq Toukan <tariqt@nvidia.com>,
"davem@davemloft.net" <davem@davemloft.net>,
"netdev@vger.kernel.org" <netdev@vger.kernel.org>,
Gal Pressman <gal@nvidia.com>, Yoray Zack <yorayz@nvidia.com>,
Leon Romanovsky <leonro@nvidia.com>,
"kuba@kernel.org" <kuba@kernel.org>,
"edumazet@google.com" <edumazet@google.com>,
Saeed Mahameed <saeedm@nvidia.com>,
"pabeni@redhat.com" <pabeni@redhat.com>
Subject: Re: [PATCH net-next 08/15] net/mlx5e: SHAMPO, Skipping on duplicate flush of the same SHAMPO SKB
Date: Thu, 6 Jun 2024 14:59:05 +0100 [thread overview]
Message-ID: <20240606135905.GL791188@kernel.org> (raw)
In-Reply-To: <9957a6c3740e76c61b979038c6e984f9987bbd4c.camel@nvidia.com>
On Wed, Jun 05, 2024 at 05:55:24PM +0000, Dragos Tatulea wrote:
> On Wed, 2024-06-05 at 14:48 +0100, Simon Horman wrote:
> > On Tue, May 28, 2024 at 05:28:00PM +0300, Tariq Toukan wrote:
> > > From: Yoray Zack <yorayz@nvidia.com>
> > >
> > > SHAMPO SKB can be flushed in mlx5e_shampo_complete_rx_cqe().
> > > If the SKB was flushed, rq->hw_gro_data->skb was also set to NULL.
> > >
> > > We can skip on flushing the SKB in mlx5e_shampo_flush_skb
> > > if rq->hw_gro_data->skb == NULL.
> > >
> > > Signed-off-by: Yoray Zack <yorayz@nvidia.com>
> > > Signed-off-by: Tariq Toukan <tariqt@nvidia.com>
> > > ---
> > > drivers/net/ethernet/mellanox/mlx5/core/en_rx.c | 2 +-
> > > 1 file changed, 1 insertion(+), 1 deletion(-)
> > >
> > > diff --git a/drivers/net/ethernet/mellanox/mlx5/core/en_rx.c b/drivers/net/ethernet/mellanox/mlx5/core/en_rx.c
> > > index 1e3a5b2afeae..3f76c33aada0 100644
> > > --- a/drivers/net/ethernet/mellanox/mlx5/core/en_rx.c
> > > +++ b/drivers/net/ethernet/mellanox/mlx5/core/en_rx.c
> > > @@ -2334,7 +2334,7 @@ static void mlx5e_handle_rx_cqe_mpwrq_shampo(struct mlx5e_rq *rq, struct mlx5_cq
> > > }
> > >
> > > mlx5e_shampo_complete_rx_cqe(rq, cqe, cqe_bcnt, *skb);
> > > - if (flush)
> > > + if (flush && rq->hw_gro_data->skb)
> > > mlx5e_shampo_flush_skb(rq, cqe, match);
> >
> > nit: It seems awkward to reach inside rq like this
> > when mlx5e_shampo_flush_skb already deals with the skb in question.
> >
> We don't need to reach inside the rq, we could use *skb instead (skb is &rq-
> >hw_gro_data->skb). *skb is used often in this function.
So it is, thanks for pointing that out.
Clearly this is a pretty minor thing,
so no need to respin just because of it.
>
> > Would it make esnse for the NULL skb check to
> > be moved inside mlx5e_shampo_flush_skb() ?
> >
>
> Thanks,
> Dragos
next prev parent reply other threads:[~2024-06-06 13:59 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-05-28 14:27 [PATCH net-next 00/15] net/mlx5e: SHAMPO, Enable HW GRO once more Tariq Toukan
2024-05-28 14:27 ` [PATCH net-next 01/15] net/mlx5e: SHAMPO, Use net_prefetch API Tariq Toukan
2024-05-28 14:27 ` [PATCH net-next 02/15] net/mlx5e: SHAMPO, Fix incorrect page release Tariq Toukan
2024-05-30 1:12 ` Jakub Kicinski
2024-05-30 3:24 ` Saeed Mahameed
2024-05-28 14:27 ` [PATCH net-next 03/15] net/mlx5e: SHAMPO, Fix invalid WQ linked list unlink Tariq Toukan
2024-05-28 14:27 ` [PATCH net-next 04/15] net/mlx5e: SHAMPO, Fix FCS config when HW GRO on Tariq Toukan
2024-05-28 14:27 ` [PATCH net-next 05/15] net/mlx5e: SHAMPO, Disable gso_size for non GRO packets Tariq Toukan
2024-05-28 14:27 ` [PATCH net-next 06/15] net/mlx5e: SHAMPO, Simplify header page release in teardown Tariq Toukan
2024-05-28 14:27 ` [PATCH net-next 07/15] net/mlx5e: SHAMPO, Specialize mlx5e_fill_skb_data() Tariq Toukan
2024-05-28 14:28 ` [PATCH net-next 08/15] net/mlx5e: SHAMPO, Skipping on duplicate flush of the same SHAMPO SKB Tariq Toukan
2024-06-05 13:48 ` Simon Horman
2024-06-05 17:55 ` Dragos Tatulea
2024-06-06 13:59 ` Simon Horman [this message]
2024-05-28 14:28 ` [PATCH net-next 09/15] net/mlx5e: SHAMPO, Make GRO counters more precise Tariq Toukan
2024-05-28 14:28 ` [PATCH net-next 10/15] net/mlx5e: SHAMPO, Drop rx_gro_match_packets counter Tariq Toukan
2024-05-28 14:28 ` [PATCH net-next 11/15] net/mlx5e: SHAMPO, Add no-split ethtool counters for header/data split Tariq Toukan
2024-05-30 1:22 ` Jakub Kicinski
2024-05-30 3:32 ` Saeed Mahameed
2024-05-30 15:31 ` Jakub Kicinski
2024-06-03 12:46 ` Dragos Tatulea
2024-05-28 14:28 ` [PATCH net-next 12/15] net/mlx5e: SHAMPO, Add header-only ethtool counters for header data split Tariq Toukan
2024-05-28 14:28 ` [PATCH net-next 13/15] net/mlx5e: SHAMPO, Use KSMs instead of KLMs Tariq Toukan
2024-05-30 1:23 ` Jakub Kicinski
2024-05-30 3:26 ` Saeed Mahameed
2024-05-28 14:28 ` [PATCH net-next 14/15] net/mlx5e: SHAMPO, Re-enable HW-GRO Tariq Toukan
2024-05-28 14:28 ` [PATCH net-next 15/15] net/mlx5e: SHAMPO, Coalesce skb fragments to page size Tariq Toukan
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=20240606135905.GL791188@kernel.org \
--to=horms@kernel.org \
--cc=davem@davemloft.net \
--cc=dtatulea@nvidia.com \
--cc=edumazet@google.com \
--cc=gal@nvidia.com \
--cc=kuba@kernel.org \
--cc=leonro@nvidia.com \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=saeedm@nvidia.com \
--cc=tariqt@nvidia.com \
--cc=yorayz@nvidia.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).