diff options
author | Christoph Hellwig <hch@lst.de> | 2006-08-07 16:09:04 -0700 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2006-08-07 16:09:04 -0700 |
commit | 7b2e497a06c0e93719fda88820e057b635e8fae2 (patch) | |
tree | 5ca55484d813656f56cf7fc86cafd041327c7dae /net/core | |
parent | 766ea8cce007e699679109df4fa469b870ba4860 (diff) | |
download | op-kernel-dev-7b2e497a06c0e93719fda88820e057b635e8fae2.zip op-kernel-dev-7b2e497a06c0e93719fda88820e057b635e8fae2.tar.gz |
[NET]: Assign skb->dev in netdev_alloc_skb
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/core')
-rw-r--r-- | net/core/skbuff.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/net/core/skbuff.c b/net/core/skbuff.c index 022d889..c54f366 100644 --- a/net/core/skbuff.c +++ b/net/core/skbuff.c @@ -268,8 +268,10 @@ struct sk_buff *__netdev_alloc_skb(struct net_device *dev, struct sk_buff *skb; skb = alloc_skb(length + NET_SKB_PAD, gfp_mask); - if (likely(skb)) + if (likely(skb)) { skb_reserve(skb, NET_SKB_PAD); + skb->dev = dev; + } return skb; } |