[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CANn89iKUDbV6U6d3hN3eZ91YkEC=vuGrOG63zTzLJ3Nfg5RVeA@mail.gmail.com>
Date: Wed, 21 Jan 2026 17:15:28 +0100
From: Eric Dumazet <edumazet@...gle.com>
To: Paolo Abeni <pabeni@...hat.com>
Cc: netdev@...r.kernel.org, "David S. Miller" <davem@...emloft.net>,
Jakub Kicinski <kuba@...nel.org>, Simon Horman <horms@...nel.org>,
Donald Hunter <donald.hunter@...il.com>, Andrew Lunn <andrew+netdev@...n.ch>,
Shuah Khan <shuah@...nel.org>, Willem de Bruijn <willemdebruijn.kernel@...il.com>, sdf@...ichev.me,
petrm@...dia.com, razor@...ckwall.org, idosch@...dia.com
Subject: Re: [PATCH v5 net-next 01/10] net: introduce mangleid_features
On Wed, Jan 21, 2026 at 5:12 PM Paolo Abeni <pabeni@...hat.com> wrote:
>
> Some/most devices implementing gso_partial need to disable the GSO partial
> features when the IP ID can't be mangled; to that extend each of them
> implements something alike the following[1]:
>
> if (skb->encapsulation && !(features & NETIF_F_TSO_MANGLEID))
> features &= ~NETIF_F_TSO;
>
> in the ndo_features_check() op, which leads to a bit of duplicate code.
>
> Later patch in the series will implement GSO partial support for virtual
> devices, and the current status quo will require more duplicate code and
> a new indirect call in the TX path for them.
>
> Introduce the mangleid_features mask, allowing the core to disable NIC
> features based on/requiring MANGLEID, without any further intervention
> from the driver.
>
> The same functionality could be alternatively implemented adding a single
> boolean flag to the struct net_device, but would require an additional
> checks in ndo_features_check().
>
> Also note that [1] is incorrect if the NIC additionally implements
> NETIF_F_GSO_UDP_L4, mangleid_features transparently handle even such a
> case.
>
> Signed-off-by: Paolo Abeni <pabeni@...hat.com>
Reviewed-by: Eric Dumazet <edumazet@...gle.com>
Powered by blists - more mailing lists