diff options
Diffstat (limited to 'drivers/net/spider_net.c')
-rw-r--r-- | drivers/net/spider_net.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/drivers/net/spider_net.c b/drivers/net/spider_net.c index 108adbf5b5eb..ef84d7c757a0 100644 --- a/drivers/net/spider_net.c +++ b/drivers/net/spider_net.c | |||
@@ -430,7 +430,8 @@ spider_net_prepare_rx_descr(struct spider_net_card *card, | |||
430 | /* and we need to have it 128 byte aligned, therefore we allocate a | 430 | /* and we need to have it 128 byte aligned, therefore we allocate a |
431 | * bit more */ | 431 | * bit more */ |
432 | /* allocate an skb */ | 432 | /* allocate an skb */ |
433 | descr->skb = dev_alloc_skb(bufsize + SPIDER_NET_RXBUF_ALIGN - 1); | 433 | descr->skb = netdev_alloc_skb(card->netdev, |
434 | bufsize + SPIDER_NET_RXBUF_ALIGN - 1); | ||
434 | if (!descr->skb) { | 435 | if (!descr->skb) { |
435 | if (netif_msg_rx_err(card) && net_ratelimit()) | 436 | if (netif_msg_rx_err(card) && net_ratelimit()) |
436 | pr_err("Not enough memory to allocate rx buffer\n"); | 437 | pr_err("Not enough memory to allocate rx buffer\n"); |
@@ -1013,12 +1014,12 @@ spider_net_pass_skb_up(struct spider_net_descr *descr, | |||
1013 | */ | 1014 | */ |
1014 | } | 1015 | } |
1015 | 1016 | ||
1016 | /* pass skb up to stack */ | ||
1017 | netif_receive_skb(skb); | ||
1018 | |||
1019 | /* update netdevice statistics */ | 1017 | /* update netdevice statistics */ |
1020 | card->netdev_stats.rx_packets++; | 1018 | card->netdev_stats.rx_packets++; |
1021 | card->netdev_stats.rx_bytes += skb->len; | 1019 | card->netdev_stats.rx_bytes += skb->len; |
1020 | |||
1021 | /* pass skb up to stack */ | ||
1022 | netif_receive_skb(skb); | ||
1022 | } | 1023 | } |
1023 | 1024 | ||
1024 | #ifdef DEBUG | 1025 | #ifdef DEBUG |