Netdev List
 help / color / mirror / Atom feed
From: Willem de Bruijn <willemdebruijn.kernel@gmail.com>
To: Jakub Kicinski <kuba@kernel.org>,  davem@davemloft.net
Cc: netdev@vger.kernel.org,  edumazet@google.com,  pabeni@redhat.com,
	 andrew+netdev@lunn.ch,  horms@kernel.org,
	 michael.chan@broadcom.com,  manishc@marvell.com,
	 joshwash@google.com,  hramamurthy@google.com,
	 tariqt@nvidia.com,  saeedm@nvidia.com,  daniel@iogearbox.net,
	 hawk@kernel.org,  sdf@fomichev.me,  willemb@google.com,
	 przemyslaw.kitszel@intel.com,  bpf@vger.kernel.org,
	 Jakub Kicinski <kuba@kernel.org>
Subject: Re: [PATCH net-next 4/8] net: state the "XDP excludes LRO" rule in the core
Date: Thu, 19 Nov 2026 18:02:49 -0500	[thread overview]
Message-ID: <willemdebruijn.kernel.32986341d4816@gmail.com> (raw)
In-Reply-To: <20261118232315.3593731-5-kuba@kernel.org>

Jakub Kicinski wrote:
> LRO is the older take on the same thing as HW-GRO. And similarly to
> HW-GRO XDP cannot be handed post-LRO frames. Drivers open-code
> the exclusion just like they did for HW-GRO, and disagree just the
> same: mlx5 and netvsc refuse the attach, bnxt and ixgbe clear the feature
> from ndo_fix_features(), vmxnet3 writes dev->features behind the core's
> back, and atlantic only minds single-buffer programs. Clear LRO next to
> HW-GRO, with the same ordering and the same refusal if a driver insists
> on keeping it.
> 
> atlantic loses LRO under a multi-buffer program now as well. XDP_TX and
> redirect can't carry the GSO metadata of a coalesced frame, however
> many buffers it spans.
> 
> Drop netif_disable_lro() from generic_xdp_install(), like the previous
> patch dropped dev_disable_gro_hw(). The core covers the device itself,
> and LRO no longer stays off after the detach.
> 
> This changes the behavior for lower devices. netif_disable_lro() walked
> them, dev_disable_gro_hw() never did. And unlike HW-GRO, LRO is in
> NETIF_F_UPPER_DISABLES, an upper which loses it clears it from the
> wanted_features of its lowers for good. bond and team carry LRO only to
> hand it down, so a program on a bond still turns LRO off on the slaves,
> and they don't get it back after the detach. Making sure lowers don't
> coalesce is a separate problem, for HW-GRO and LRO alike.
> 
> LRO state with the program [attached / after it's detached], netdevsim
> as the single device, bond of two vmxnet3 ports:
> 
>   program on    device   w/o patch    w/ patch
>   ------------  -------  -----------  ---------
>   dev, native   dev      on  / on `1  off / on
>   dev, generic  dev      off / off    off / on
>   bond, native  bond     on  / on     off / on
>                 slaves   off / off`2  off / off
>   bond, generic bond     off / off    off / on
>                 slaves   off / off    off / off
> 
>  `1 netdevsim ignores LRO under XDP, real drivers turned it off one
>     way or another
>  `2 vmxnet3 clears LRO from dev->features by itself and nothing turns
>     it back on, bnxt slaves would get it back
> 
> Ideally we'd want [off / on] (XDP disables LRO, LRO comes back once
> XDP is cleared). But the two "off"s after detach on slaves are not
> worth the complexity IMHO.
> 
> Signed-off-by: Jakub Kicinski <kuba@kernel.org>

Reviewed-by: Willem de Bruijn <willemb@google.com>

  reply	other threads:[~2026-11-19 23:02 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-18 23:23 [PATCH net-next 0/8] net: adjust HW GRO and LRO feature handling Jakub Kicinski
2026-11-18 23:23 ` [PATCH net-next 1/8] net: stop making HW-GRO depend on SW GRO Jakub Kicinski
2026-11-18 23:23 ` [PATCH net-next 2/8] selftests: drv-net: drop the generic XDP hack from the HW GRO setup Jakub Kicinski
2026-11-19 21:40   ` Willem de Bruijn
2026-11-18 23:23 ` [PATCH net-next 3/8] net: state the "XDP excludes HW-GRO" rule in the core Jakub Kicinski
2026-11-19 22:59   ` Willem de Bruijn
2026-11-18 23:23 ` [PATCH net-next 4/8] net: state the "XDP excludes LRO" " Jakub Kicinski
2026-11-19 23:02   ` Willem de Bruijn [this message]
2026-11-18 23:23 ` [PATCH net-next 5/8] eth: mlx5e: drop the now-dead HW-GRO and LRO vs XDP handling Jakub Kicinski
2026-11-19 15:42   ` Dragos Tatulea
2026-11-18 23:23 ` [PATCH net-next 6/8] eth: bnxt_en: don't clear HW-GRO and LRO for XDP in ndo_fix_features Jakub Kicinski
2026-11-18 23:23 ` [PATCH net-next 7/8] eth: qede: drop the now-dead HW-GRO vs XDP handling Jakub Kicinski
2026-11-18 23:23 ` [PATCH net-next 8/8] eth: gve: drop the now-dead HW-GRO vs XDP interlock Jakub Kicinski
2026-11-18 23:44   ` Ankit Garg
2026-11-19 22:14   ` Harshitha Ramamurthy

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=willemdebruijn.kernel.32986341d4816@gmail.com \
    --to=willemdebruijn.kernel@gmail.com \
    --cc=andrew+netdev@lunn.ch \
    --cc=bpf@vger.kernel.org \
    --cc=daniel@iogearbox.net \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=hawk@kernel.org \
    --cc=horms@kernel.org \
    --cc=hramamurthy@google.com \
    --cc=joshwash@google.com \
    --cc=kuba@kernel.org \
    --cc=manishc@marvell.com \
    --cc=michael.chan@broadcom.com \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=przemyslaw.kitszel@intel.com \
    --cc=saeedm@nvidia.com \
    --cc=sdf@fomichev.me \
    --cc=tariqt@nvidia.com \
    --cc=willemb@google.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