netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [RFC net-next v1 0/6] nmdesc cleanups and optimisations
@ 2025-08-11 16:29 Pavel Begunkov
  2025-08-11 16:29 ` [RFC net-next v1 1/6] net: move pp_page_to_nmdesc() Pavel Begunkov
                   ` (5 more replies)
  0 siblings, 6 replies; 16+ messages in thread
From: Pavel Begunkov @ 2025-08-11 16:29 UTC (permalink / raw)
  To: netdev
  Cc: Jakub Kicinski, Eric Dumazet, Paolo Abeni, davem, sdf,
	almasrymina, dw, Jesper Dangaard Brouer, Ilias Apalodimas,
	Byungchul Park, asml.silence

This series uses newly introduced struct netmem_desc, which represents
common fields b/w netmem types, for optimisations and to start
addressing some of the netmem technical debt.

First, replace __netmem_clear_lsb with netmem_to_nmdesc(). The helper
optimises pp fields accesses, but now we can do the same but cleaner.

The second problem is abundance of places where the user has struct
page / net_iov but still needs to cast it to netmem back and forth
just to be able to use generic helpers. It's not the prettiest
pattern and often can't be optimised. Start introducing netmem_desc
based helpers and using them instead.

There is more work we can do, but these are the patches I want to
pull into zcrx. It's an RFC for now, I'll send it as a pull request
without zcrx bits.

Byungchul Park (1):
  net: replace __netmem_clear_lsb() with netmem_to_nmdesc()

Pavel Begunkov (5):
  net: move pp_page_to_nmdesc()
  net: page_pool: remove page_pool_set_dma_addr()
  net: convert page pool dma helpers to netmem_desc
  net: page_pool: convert refcounting helpers to nmdesc
  io_uring/zcrx: avoid netmem casts with nmdesc

 include/net/netmem.h            | 75 +++++++++++++++------------------
 include/net/page_pool/helpers.h | 41 ++++++++++++++----
 io_uring/zcrx.c                 | 12 +++---
 net/core/devmem.c               |  5 ---
 net/core/netmem_priv.h          | 20 +++------
 net/core/page_pool_priv.h       | 14 +++---
 6 files changed, 82 insertions(+), 85 deletions(-)

-- 
2.49.0


^ permalink raw reply	[flat|nested] 16+ messages in thread

end of thread, other threads:[~2025-08-14  8:41 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-08-11 16:29 [RFC net-next v1 0/6] nmdesc cleanups and optimisations Pavel Begunkov
2025-08-11 16:29 ` [RFC net-next v1 1/6] net: move pp_page_to_nmdesc() Pavel Begunkov
2025-08-12 23:55   ` Mina Almasry
2025-08-11 16:29 ` [RFC net-next v1 2/6] net: replace __netmem_clear_lsb() with netmem_to_nmdesc() Pavel Begunkov
2025-08-11 16:29 ` [RFC net-next v1 3/6] net: page_pool: remove page_pool_set_dma_addr() Pavel Begunkov
2025-08-13  0:00   ` Mina Almasry
2025-08-11 16:29 ` [RFC net-next v1 4/6] net: convert page pool dma helpers to netmem_desc Pavel Begunkov
2025-08-13  0:05   ` Mina Almasry
2025-08-13  8:34     ` Pavel Begunkov
2025-08-11 16:29 ` [RFC net-next v1 5/6] net: page_pool: convert refcounting helpers to nmdesc Pavel Begunkov
2025-08-13  0:14   ` Mina Almasry
2025-08-13  9:11     ` Pavel Begunkov
2025-08-13 16:55       ` Mina Almasry
2025-08-14  8:43         ` Pavel Begunkov
2025-08-11 16:29 ` [RFC net-next v1 6/6] io_uring/zcrx: avoid netmem casts with nmdesc Pavel Begunkov
2025-08-13  0:16   ` Mina Almasry

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).