When reading the source, I can see in:
. alloc_skb()
139 size = ((size + 15) & ~15);
140 data = kmalloc(size + sizeof(atomic_t), gfp_mask);
I understand the size stuff (the sk_buff content is 16-bytes aligned to be
cache-friendly I guess).
But why actually allocating size + the size of an atomic_t, which will
break this alignment?
. dev_alloc_skb() seems to allocate 16 bytes more than needed as head
room. What is the purpose of this? How can I choose which one of
alloc_skb() or dev_alloc_skb() will suit my needs?
Thanks in advance for your answers,
Best regards,
-- Regis "HPReg" Duchesne - Engineering Student at ***** ******** ***** www http://www.via.ecp.fr/~regis/ (O o) I use Linux & 3Com (1135 KB/s over 10Mb/s ethernet) --.oOO--(_)--OOo.-----------------------------------------------------------
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/