From: Stephen Hemminger Date: Wed, 16 Apr 2008 23:37:35 +0000 (-0700) Subject: ns8320: use netdev_alloc_skb X-Git-Tag: MMI-PSA29.97-13-9~33552^2~368 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=e83728c7b0ce92e57aa90eb4fc271a29d7a393d5;p=GitHub%2FMotorolaMobilityLLC%2Fkernel-slsi.git ns8320: use netdev_alloc_skb Use netdev_alloc_skb. This sets skb->dev and allows arch specific allocation. Compile tested only. Signed-off-by: Stephen Hemminger Signed-off-by: Jeff Garzik --- diff --git a/drivers/net/ns83820.c b/drivers/net/ns83820.c index b42c05f84be1..ff449619f047 100644 --- a/drivers/net/ns83820.c +++ b/drivers/net/ns83820.c @@ -585,16 +585,13 @@ static inline int rx_refill(struct net_device *ndev, gfp_t gfp) for (i=0; idata & 0xf; - res = 0x10 - res; - res &= 0xf; - skb_reserve(skb, res); - + skb_reserve(skb, skb->data - PTR_ALIGN(skb->data, 16)); if (gfp != GFP_ATOMIC) spin_lock_irqsave(&dev->rx_info.lock, flags); res = ns83820_add_rx_skb(dev, skb);