net: core: use a dedicated kmem_cache for skb head allocs
Status from this message: This series was applied to netdev/net-next.git (master)
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v2 Latest4 patches 2 repliesApplied 4/4
- v14 patches 11 repliesSuperseded
Patches in v2 All 4 applied
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/4 | net: add SKB_HEAD_ALIGN() helperinclude/ net/ | +14 | 0 replies | Applied |
| 2/4 | net: remove osize variable in __alloc_skb()net/ | +4 | 0 replies | Applied |
| 3/4 | net: factorize code in kmalloc_reserve()net/ | +11 | 0 replies | Applied |
| 4/4 | net: add dedicated kmem_cache for typical/small skb->headnet/ | +67 | 1 reply | Applied |
Reviews trailers per patch
All 4 patches have a Reviewed-by or Acked-by of their own; the series has one for all of them.
| Patch | Soheil Hassas Yeganeh | Alexander Duyck |
|---|---|---|
| Series | R-b | |
| 1/4 | A-b | |
| 2/4 | A-b | |
| 3/4 | A-b | |
| 4/4 | A-b |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH v2 net-next 0/4] net: core: use a dedicated kmem_cache for skb head allocs
Our profile data show that using kmalloc(non_const_size)/kfree(ptr) has a certain cost, because kfree(ptr) has to pull a 'struct page' in cpu caches.
Using a dedicated kmem_cache for TCP skb->head allocations makes a difference, both in cpu cycles and memory savings.
This kmem_cache could also be used for GRO skb allocations, this is left as a future exercise.
v2: addressed compile error with CONFIG_SLOB=y (kernel bots)
Changed comment (Jakub)
Eric Dumazet (4):
net: add SKB_HEAD_ALIGN() helper
net: remove osize variable in __alloc_skb()
net: factorize code in kmalloc_reserve()
net: add dedicated kmem_cache for typical/small skb->head
include/linux/skbuff.h | 8 +++ net/core/skbuff.c | 115 +++++++++++++++++++++++++++++------------ 2 files changed, 90 insertions(+), 33 deletions(-)
Signature · 1 line
2.39.1.519.gcb327c4b5f-goog