From: Joe Damato <joe@dama.to>
To: Eric Dumazet <edumazet@google.com>
Cc: "David S . Miller" <davem@davemloft.net>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
Simon Horman <horms@kernel.org>,
Andrew Lunn <andrew+netdev@lunn.ch>,
netdev@vger.kernel.org, eric.dumazet@gmail.com
Subject: Re: [PATCH net-next 2/2] net: pull headers in qdisc_pkt_len_segs_init()
Date: Mon, 6 Apr 2026 11:40:01 -0700 [thread overview]
Message-ID: <adP+AeuYK0eq0q0V@devvm20253.cco0.facebook.com> (raw)
In-Reply-To: <20260403221540.3297753-3-edumazet@google.com>
On Fri, Apr 03, 2026 at 10:15:40PM +0000, Eric Dumazet wrote:
> Most ndo_start_xmit() methods expects headers of gso packets
> to be already in skb->head.
>
> net/core/tso.c users are particularly at risk, because tso_build_hdr()
> does a memcpy(hdr, skb->data, hdr_len);
>
> qdisc_pkt_len_segs_init() already does a dissection of gso packets.
>
> Use pskb_may_pull() instead of skb_header_pointer() to make
> sure drivers do not have to reimplement this.
>
> Some malicious packets could be fed, detect them so that we can
> drop them sooner with a new SKB_DROP_REASON_SKB_BAD_GSO drop_reason.
>
> Fixes: e876f208af18 ("net: Add a software TSO helper API")
> Signed-off-by: Eric Dumazet <edumazet@google.com>
> ---
> include/net/dropreason-core.h | 3 +++
> net/core/dev.c | 51 +++++++++++++++++++++--------------
> 2 files changed, 34 insertions(+), 20 deletions(-)
>
Reviewed-by: Joe Damato <joe@dama.to>
next prev parent reply other threads:[~2026-04-06 18:40 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-04-03 22:15 [PATCH net-next 0/2] net: pull gso packet headers in core stack Eric Dumazet
2026-04-03 22:15 ` [PATCH net-next 1/2] net: qdisc_pkt_len_segs_init() cleanup Eric Dumazet
2026-04-06 18:37 ` Joe Damato
2026-04-03 22:15 ` [PATCH net-next 2/2] net: pull headers in qdisc_pkt_len_segs_init() Eric Dumazet
2026-04-06 18:40 ` Joe Damato [this message]
2026-04-08 3:10 ` [PATCH net-next 0/2] net: pull gso packet headers in core stack patchwork-bot+netdevbpf
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=adP+AeuYK0eq0q0V@devvm20253.cco0.facebook.com \
--to=joe@dama.to \
--cc=andrew+netdev@lunn.ch \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=eric.dumazet@gmail.com \
--cc=horms@kernel.org \
--cc=kuba@kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.