netdev: ethernet dev_alloc_skb to netdev_alloc_skb
Replaced deprecating dev_alloc_skb with netdev_alloc_skb in drivers/net/ethernet - Removed extra skb->dev = dev after netdev_alloc_skb Signed-off-by: Pradeep A Dalvi <netdev@pradeepdalvi.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:

committed by
David S. Miller

parent
1d26643054
commit
21a4e46995
@@ -69,7 +69,8 @@ int tulip_refill_rx(struct net_device *dev)
|
||||
struct sk_buff *skb;
|
||||
dma_addr_t mapping;
|
||||
|
||||
skb = tp->rx_buffers[entry].skb = dev_alloc_skb(PKT_BUF_SZ);
|
||||
skb = tp->rx_buffers[entry].skb =
|
||||
netdev_alloc_skb(dev, PKT_BUF_SZ);
|
||||
if (skb == NULL)
|
||||
break;
|
||||
|
||||
@@ -77,7 +78,6 @@ int tulip_refill_rx(struct net_device *dev)
|
||||
PCI_DMA_FROMDEVICE);
|
||||
tp->rx_buffers[entry].mapping = mapping;
|
||||
|
||||
skb->dev = dev; /* Mark as being used by this device. */
|
||||
tp->rx_ring[entry].buffer1 = cpu_to_le32(mapping);
|
||||
refilled++;
|
||||
}
|
||||
@@ -202,7 +202,7 @@ int tulip_poll(struct napi_struct *napi, int budget)
|
||||
/* Check if the packet is long enough to accept without copying
|
||||
to a minimally-sized skbuff. */
|
||||
if (pkt_len < tulip_rx_copybreak &&
|
||||
(skb = dev_alloc_skb(pkt_len + 2)) != NULL) {
|
||||
(skb = netdev_alloc_skb(dev, pkt_len + 2)) != NULL) {
|
||||
skb_reserve(skb, 2); /* 16 byte align the IP header */
|
||||
pci_dma_sync_single_for_cpu(tp->pdev,
|
||||
tp->rx_buffers[entry].mapping,
|
||||
@@ -428,7 +428,7 @@ static int tulip_rx(struct net_device *dev)
|
||||
/* Check if the packet is long enough to accept without copying
|
||||
to a minimally-sized skbuff. */
|
||||
if (pkt_len < tulip_rx_copybreak &&
|
||||
(skb = dev_alloc_skb(pkt_len + 2)) != NULL) {
|
||||
(skb = netdev_alloc_skb(dev, pkt_len + 2)) != NULL) {
|
||||
skb_reserve(skb, 2); /* 16 byte align the IP header */
|
||||
pci_dma_sync_single_for_cpu(tp->pdev,
|
||||
tp->rx_buffers[entry].mapping,
|
||||
|
Reference in New Issue
Block a user