diff options
Diffstat (limited to 'drivers/net/bcm63xx_enet.c')
-rw-r--r-- | drivers/net/bcm63xx_enet.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/drivers/net/bcm63xx_enet.c b/drivers/net/bcm63xx_enet.c index ba29dc319b34..1f6c5486d715 100644 --- a/drivers/net/bcm63xx_enet.c +++ b/drivers/net/bcm63xx_enet.c | |||
@@ -320,16 +320,13 @@ static int bcm_enet_receive_queue(struct net_device *dev, int budget) | |||
320 | if (len < copybreak) { | 320 | if (len < copybreak) { |
321 | struct sk_buff *nskb; | 321 | struct sk_buff *nskb; |
322 | 322 | ||
323 | nskb = netdev_alloc_skb(dev, len + NET_IP_ALIGN); | 323 | nskb = netdev_alloc_skb_ip_align(dev, len); |
324 | if (!nskb) { | 324 | if (!nskb) { |
325 | /* forget packet, just rearm desc */ | 325 | /* forget packet, just rearm desc */ |
326 | priv->stats.rx_dropped++; | 326 | priv->stats.rx_dropped++; |
327 | continue; | 327 | continue; |
328 | } | 328 | } |
329 | 329 | ||
330 | /* since we're copying the data, we can align | ||
331 | * them properly */ | ||
332 | skb_reserve(nskb, NET_IP_ALIGN); | ||
333 | dma_sync_single_for_cpu(kdev, desc->address, | 330 | dma_sync_single_for_cpu(kdev, desc->address, |
334 | len, DMA_FROM_DEVICE); | 331 | len, DMA_FROM_DEVICE); |
335 | memcpy(nskb->data, skb->data, len); | 332 | memcpy(nskb->data, skb->data, len); |