All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jason Gunthorpe <jgg@nvidia.com>
To: Mina Almasry <almasrymina@google.com>
Cc: "Yunsheng Lin" <linyunsheng@huawei.com>,
	linux-kernel@vger.kernel.org, netdev@vger.kernel.org,
	"David S. Miller" <davem@davemloft.net>,
	"Eric Dumazet" <edumazet@google.com>,
	"Jakub Kicinski" <kuba@kernel.org>,
	"Paolo Abeni" <pabeni@redhat.com>,
	"Christian König" <christian.koenig@amd.com>,
	"Shakeel Butt" <shakeelb@google.com>,
	"Willem de Bruijn" <willemdebruijn.kernel@gmail.com>
Subject: Re: [RFC PATCH net-next v5 2/2] net: add netmem to skb_frag_t
Date: Mon, 15 Jan 2024 20:01:29 -0400	[thread overview]
Message-ID: <20240116000129.GX734935@nvidia.com> (raw)
In-Reply-To: <CAHS8izOnhtQGeQ-EFmYjZyZ0eW2LqO0Rrm73eAB2su=UA34yTw@mail.gmail.com>

On Mon, Jan 15, 2024 at 03:23:33PM -0800, Mina Almasry wrote:
> > > You did not answer my question that I asked here, and ignoring this
> > > question is preventing us from making any forward progress on this
> > > discussion. What do you expect or want skb_frag_page() to do when
> > > there is no page in the frag?
> >
> > I would expect it to do nothing.
> 
> I don't understand. skb_frag_page() with an empty implementation just
> results in a compiler error as the function needs to return a page
> pointer. Do you actually expect skb_frag_page() to unconditionally
> cast frag->netmem to a page pointer? That was explained as
> unacceptable over and over again by Jason and Christian as it risks
> casting devmem to page; completely unacceptable and will get nacked.
> Do you have a suggestion of what skb_frag_page() should do that will
> not get nacked by mm?

WARN_ON and return NULL seems reasonable?

Jason

  reply	other threads:[~2024-01-16  0:01 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-01-09  1:14 [RFC PATCH net-next v5 0/2] Abstract page from net stack Mina Almasry
2024-01-09  1:14 ` [RFC PATCH net-next v5 1/2] net: introduce abstraction for network memory Mina Almasry
2024-01-10 18:45   ` Shakeel Butt
2024-01-09  1:14 ` [RFC PATCH net-next v5 2/2] net: add netmem to skb_frag_t Mina Almasry
2024-01-11 12:44   ` Yunsheng Lin
2024-01-12  0:34     ` Mina Almasry
2024-01-12 11:51       ` Yunsheng Lin
2024-01-12 15:35         ` Mina Almasry
2024-01-15  9:37           ` Yunsheng Lin
2024-01-15 23:23             ` Mina Almasry
2024-01-16  0:01               ` Jason Gunthorpe [this message]
2024-01-16 11:04                 ` Yunsheng Lin
2024-01-16 12:16                   ` Jason Gunthorpe
2024-01-17  9:28                     ` Yunsheng Lin
2024-01-17 18:00                     ` Mina Almasry
2024-01-17 18:34                       ` Mina Almasry
2024-01-17 18:54                         ` Willem de Bruijn
2024-01-18  8:52                           ` Yunsheng Lin
2024-01-18 13:56                           ` Mina Almasry
2024-01-10  2:03 ` [RFC PATCH net-next v5 0/2] Abstract page from net stack Jakub Kicinski

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=20240116000129.GX734935@nvidia.com \
    --to=jgg@nvidia.com \
    --cc=almasrymina@google.com \
    --cc=christian.koenig@amd.com \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linyunsheng@huawei.com \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=shakeelb@google.com \
    --cc=willemdebruijn.kernel@gmail.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.