Netdev List
 help / color / mirror / Atom feed
From: Willem de Bruijn <willemdebruijn.kernel@gmail.com>
To: Mina Almasry <almasrymina@google.com>,  netdev@vger.kernel.org
Cc: Mina Almasry <almasrymina@google.com>,
	 Eric Dumazet <edumazet@kernel.org>,
	 Neal Cardwell <ncardwell@google.com>,
	 Kuniyuki Iwashima <kuniyu@google.com>,
	 "David S. Miller" <davem@davemloft.net>,
	 Jakub Kicinski <kuba@kernel.org>,
	 Paolo Abeni <pabeni@redhat.com>,
	 Simon Horman <horms@kernel.org>,
	 Stanislav Fomichev <sdf@fomichev.me>,
	 Kaiyuan Zhang <kaiyuanz@google.com>,
	 Willem de Bruijn <willemb@google.com>,
	 Daniel Borkmann <daniel@iogearbox.net>,
	 Josef Bacik <josef@toxicpanda.com>,
	 Stanislav Fomichev <sdf.kernel@gmail.com>,
	 Dragos Tatulea <dtatulea@nvidia.com>,
	 Pavel Begunkov <asml.silence@gmail.com>,
	 Bobby Eshleman <bobbyeshleman@meta.com>
Subject: Re: [PATCH net-next v6 0/7] net: prevent mixing incompatible memory providers in skbs
Date: Tue, 24 Nov 2026 09:38:03 -0500	[thread overview]
Message-ID: <willemdebruijn.kernel.18018d6cd8e06@gmail.com> (raw)
In-Reply-To: <20261120201408.3445445-1-almasrymina@google.com>

Mina Almasry wrote:
> Enforce that all fragments in a nonlinear skb come from compatible
> memory providers (and for devmem, the exact same binding).

Is the following correct. Not an automatic need for respin. Can also be
addressed in a follow-up.

    IP defragmentation (inet_frag_reasm_finish() in net/ipv4/inet_fragment.c) is
    still a gap for the frag_list invariant this series enforces in
    skb_gro_receive_list() and skb_segment(). Neither ip_frag_queue() nor
    ipv6_frag_rcv() rejects unreadable skbs, and when skb_try_coalesce(head, fp,
    ...) returns false because head and fp come from incompatible providers (or
    readable + unreadable), inet_frag_reasm_finish() falls through to its else
    branch and chains fp onto head->frag_list anyway without propagating
    fp->unreadable to head->unreadable. If head is readable and fp is unreadable,
    the resulting reassembled skb has head->unreadable == 0 with an unreadable
    frag_list member, bypassing validate_xmit_unreadable_skb() on forwarding.
    Please clarify whether IP defrag is intentionally left to a follow-up (like
    head_frag-on-unreadable) or handle/reject unreadable fragments in defrag.

NB fragments here has two meanings, skb frags and IP fragments. Where
possible, please use unambiguous wording.

      parent reply	other threads:[~2026-11-24 14:38 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-20 20:14 [PATCH net-next v6 0/7] net: prevent mixing incompatible memory providers in skbs Mina Almasry
2026-11-20 20:14 ` [PATCH net-next v6 1/7] net: fix skb->unreadable propagation in skb_split() and skb_shift() Mina Almasry
2026-11-20 20:14 ` [PATCH net-next v6 2/7] net: devmem: prevent mixing TX bindings and reject non-devmem xmit Mina Almasry
2026-11-23 17:29   ` Stanislav Fomichev
2026-11-20 20:14 ` [PATCH net-next v6 3/7] tcp: fix unreadable net_iov handling in tcp_clone_payload() Mina Almasry
2026-11-23 17:29   ` Stanislav Fomichev
2026-11-24  8:14   ` netdev-bot+sashiko
2026-11-20 20:14 ` [PATCH net-next v6 4/7] tcp: propagate skb_zcopy() uarg in tcp_mtu_probe() Mina Almasry
2026-11-24  8:14   ` netdev-bot+sashiko
2026-11-20 20:14 ` [PATCH net-next v6 5/7] net: kunit: attach net_iov frags to target skbs in unreadable tests Mina Almasry
2026-11-23 17:29   ` Stanislav Fomichev
2026-11-24  8:14   ` netdev-bot+sashiko
2026-11-20 20:14 ` [PATCH net-next v6 6/7] net: prevent mixing frags from different memory providers or bindings Mina Almasry
2026-11-23 17:30   ` Stanislav Fomichev
2026-11-24  8:14   ` netdev-bot+sashiko
2026-11-20 20:14 ` [PATCH net-next v6 7/7] net: kunit: test incompatible memory provider rejection Mina Almasry
2026-11-23 17:31   ` Stanislav Fomichev
2026-11-24 14:38 ` Willem de Bruijn [this message]

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.18018d6cd8e06@gmail.com \
    --to=willemdebruijn.kernel@gmail.com \
    --cc=almasrymina@google.com \
    --cc=asml.silence@gmail.com \
    --cc=bobbyeshleman@meta.com \
    --cc=daniel@iogearbox.net \
    --cc=davem@davemloft.net \
    --cc=dtatulea@nvidia.com \
    --cc=edumazet@kernel.org \
    --cc=horms@kernel.org \
    --cc=josef@toxicpanda.com \
    --cc=kaiyuanz@google.com \
    --cc=kuba@kernel.org \
    --cc=kuniyu@google.com \
    --cc=ncardwell@google.com \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=sdf.kernel@gmail.com \
    --cc=sdf@fomichev.me \
    --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