6 * include linux/skbuff.h
8 - struct net\\_device *dev
9 * alloc\\_skb(len, gfp)
10 * dev\\_alloc\\_skb(len) - uses ATOMIC, reserves PAD
11 * netdev\\_alloc\\_skb(netdev, len) - uses ATOMIC, since 2.6.18
12 * kfree\\_skb, dev\\_kfree\\_skb
16 * head - start of allocated buffer
17 * end - end of allocated buffer
18 * data - start of data, giving space after headroom
19 * tail - end of used space
20 * headroom - space between head and data
21 * tailroom - space between tail and end
23 # Socket Buffers operations
25 * skb\\_put(skb, len) - adds data to end of skb
26 * skb\\_push(skb, len) - adds data to start of skb
27 * skb\\_pull(skb, len) - allocates headroom
28 * skb\\_headroom and skb\\_tailroom
29 * skb\\_reserve - only allowed for empty buffer, reserves headroom
30 * skb\\_orphan - release it from its socket holder
34 * include linux/netdevice.h
47 # Network Device Setup
49 * alloc\\_netdev(szpriv, name, setup)
51 * include linux/etherdevice.h
58 # Network Device Operations
60 * struct net\\_device\\_ops
63 - should call netif\\_start\\_queue
65 - should call netif\\_stop\\_queue
67 # Network Device Address
71 * random\\_ether\\_addr
72 * struct net\\_device\\_ops
73 - ndo\\_set\\_mac\\_address
79 * called with a held lock
81 # Limits on transmission
83 * When TX buffers are full, xmit may call netif\\_stop\\_queue
84 * Should arrange to get netif\\_wake\\_queue called after TX buffers are free
87 # Transmission timeout
91 # Changes in net device
93 * Use netdev\\_priv, no priv anymore
94 * struct net\\_device\\_ops introduced in 2.6.29, with compatibility provided
96 * Compatibility removed in 2.6.31
97 * netdev\\_tx\\_t: NETDEV\\_TX\\_OK, NETDEV\\_TX\\_BUSY, NETDEV\\_TX\\_LOCKED
99 # Other recent changes
101 * Some members moved to netdev\\_queue to increase cache-line usage
103 * Multi-queue support
104 * RPS - Packet Steering