ixp2000: use netdev_alloc_skb
authorStephen Hemminger <shemminger@vyatta.com>
Wed, 16 Apr 2008 23:37:37 +0000 (16:37 -0700)
committerJeff Garzik <jgarzik@redhat.com>
Thu, 22 May 2008 18:12:39 +0000 (14:12 -0400)
Use netdev_alloc_skb. This sets skb->dev and allows arch specific
allocation.

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
drivers/net/ixp2000/ixpdev.c

index 484cb2ba717f97d1df4f84b43701a9b7cf7b4bca..7111c65f0b30e4b2e3e77f999cf500e6304bba2b 100644 (file)
@@ -108,14 +108,14 @@ static int ixpdev_rx(struct net_device *dev, int processed, int budget)
                if (unlikely(!netif_running(nds[desc->channel])))
                        goto err;
 
-               skb = dev_alloc_skb(desc->pkt_length + 2);
+               skb = netdev_alloc_skb(dev, desc->pkt_length + 2);
                if (likely(skb != NULL)) {
                        skb_reserve(skb, 2);
                        skb_copy_to_linear_data(skb, buf, desc->pkt_length);
                        skb_put(skb, desc->pkt_length);
                        skb->protocol = eth_type_trans(skb, nds[desc->channel]);
 
-                       skb->dev->last_rx = jiffies;
+                       dev->last_rx = jiffies;
 
                        netif_receive_skb(skb);
                }