[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20250509115126.63190-13-byungchul@sk.com>
Date: Fri, 9 May 2025 20:51:19 +0900
From: Byungchul Park <byungchul@...com>
To: willy@...radead.org,
netdev@...r.kernel.org
Cc: linux-kernel@...r.kernel.org,
linux-mm@...ck.org,
kernel_team@...ynix.com,
kuba@...nel.org,
almasrymina@...gle.com,
ilias.apalodimas@...aro.org,
harry.yoo@...cle.com,
hawk@...nel.org,
akpm@...ux-foundation.org,
ast@...nel.org,
daniel@...earbox.net,
davem@...emloft.net,
john.fastabend@...il.com,
andrew+netdev@...n.ch,
edumazet@...gle.com,
pabeni@...hat.com,
vishal.moola@...il.com
Subject: [RFC 12/19] netmem: introduce page_pool_recycle_direct_netmem()
All the callers to page_pool_recycle_direct() need to be converted to
use netmem descriptor and API instead of struct page things.
As part of the work, introduce page_pool_recycle_direct_netmem()
allowing the callers to use netmem descriptor and API.
Signed-off-by: Byungchul Park <byungchul@...com>
---
include/net/page_pool/helpers.h | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/include/net/page_pool/helpers.h b/include/net/page_pool/helpers.h
index 582a3d00cbe23..9b7a3a996bbea 100644
--- a/include/net/page_pool/helpers.h
+++ b/include/net/page_pool/helpers.h
@@ -395,6 +395,12 @@ static inline void page_pool_recycle_direct(struct page_pool *pool,
page_pool_put_full_page(pool, page, true);
}
+static inline void page_pool_recycle_direct_netmem(struct page_pool *pool,
+ netmem_ref netmem)
+{
+ page_pool_put_full_netmem(pool, netmem, true);
+}
+
#define PAGE_POOL_32BIT_ARCH_WITH_64BIT_DMA \
(sizeof(dma_addr_t) > sizeof(unsigned long))
--
2.17.1
Powered by blists - more mailing lists