Re: [PATCH net] xdp: use multi-buff only if receive queue supports page pool

From
Jakub Kicinski <kuba@kernel.org>
Date
2025-09-30 17:41:31
Also in
bpf
Reply to
Octavian Purdila, 2025-09-30
On Mon, 29 Sep 2025 17:01:49 -0700 Octavian Purdila wrote:
quoted hunk ↗ jump to hunk
        local_lock_nested_bh(&system_page_pool.bh_lock);
-       err = skb_cow_data_for_xdp(this_cpu_read(system_page_pool.pool), pskb, prog);
+       pool = this_cpu_read(system_page_pool.pool);
+       err = skb_cow_data_for_xdp(pool, pskb, prog);
+       rxq->mem.type = MEM_TYPE_PAGE_POOL;
+       rxq->mem.id = pool->xdp_mem_id;
        local_unlock_nested_bh(&system_page_pool.bh_lock);
Yes, LGTM. I _think_ that only skb_cow_data_for_xdp() has to be under
the lock here, but doesn't really matter.
Thread (10 messages) 10 messages, 3 authors, last reply 2025-09-30
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help