netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net-next v4 0/2] optimise local CPU skb_attempt_defer_free
@ 2024-04-10  1:28 Pavel Begunkov
  2024-04-10  1:28 ` [PATCH net-next v4 1/2] net: cache for same cpu skb_attempt_defer_free Pavel Begunkov
                   ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: Pavel Begunkov @ 2024-04-10  1:28 UTC (permalink / raw)
  To: netdev; +Cc: edumazet, davem, dsahern, pabeni, kuba, Pavel Begunkov

Optimise the case when an skb comes to skb_attempt_defer_free()
on the same CPU it was allocated on. The patch 1 enables skb caches
and gives frags a chance to hit the page pool's fast path.
CPU bound benchmarking with perfect skb_attempt_defer_free()
gives around 1% of extra throughput.

v4: SKB_DROP_REASON_NOT_SPECIFIED -> SKB_CONSUMED
v3: rebased, no changes otherwise
v2: pass @napi_safe=true by using __napi_kfree_skb()

Pavel Begunkov (2):
  net: cache for same cpu skb_attempt_defer_free
  net: use SKB_CONSUMED in skb_attempt_defer_free()

 net/core/skbuff.c | 15 ++++++++++++++-
 1 file changed, 14 insertions(+), 1 deletion(-)

-- 
2.44.0


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

end of thread, other threads:[~2024-04-11  2:55 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-04-10  1:28 [PATCH net-next v4 0/2] optimise local CPU skb_attempt_defer_free Pavel Begunkov
2024-04-10  1:28 ` [PATCH net-next v4 1/2] net: cache for same cpu skb_attempt_defer_free Pavel Begunkov
2024-04-10 18:47   ` Eric Dumazet
2024-04-11  2:54   ` Jason Xing
2024-04-10  1:28 ` [PATCH net-next v4 2/2] net: use SKB_CONSUMED in skb_attempt_defer_free() Pavel Begunkov
2024-04-10 18:47   ` Eric Dumazet
2024-04-11  2:30 ` [PATCH net-next v4 0/2] optimise local CPU skb_attempt_defer_free patchwork-bot+netdevbpf

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).