aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/skge.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/skge.c')
-rw-r--r--drivers/net/skge.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/drivers/net/skge.c b/drivers/net/skge.c
index 01f6811f1324..be28ebb3811c 100644
--- a/drivers/net/skge.c
+++ b/drivers/net/skge.c
@@ -3070,11 +3070,10 @@ static struct sk_buff *skge_rx_get(struct net_device *dev,
3070 goto error; 3070 goto error;
3071 3071
3072 if (len < RX_COPY_THRESHOLD) { 3072 if (len < RX_COPY_THRESHOLD) {
3073 skb = netdev_alloc_skb(dev, len + 2); 3073 skb = netdev_alloc_skb_ip_align(dev, len);
3074 if (!skb) 3074 if (!skb)
3075 goto resubmit; 3075 goto resubmit;
3076 3076
3077 skb_reserve(skb, 2);
3078 pci_dma_sync_single_for_cpu(skge->hw->pdev, 3077 pci_dma_sync_single_for_cpu(skge->hw->pdev,
3079 pci_unmap_addr(e, mapaddr), 3078 pci_unmap_addr(e, mapaddr),
3080 len, PCI_DMA_FROMDEVICE); 3079 len, PCI_DMA_FROMDEVICE);
@@ -3085,11 +3084,11 @@ static struct sk_buff *skge_rx_get(struct net_device *dev,
3085 skge_rx_reuse(e, skge->rx_buf_size); 3084 skge_rx_reuse(e, skge->rx_buf_size);
3086 } else { 3085 } else {
3087 struct sk_buff *nskb; 3086 struct sk_buff *nskb;
3088 nskb = netdev_alloc_skb(dev, skge->rx_buf_size + NET_IP_ALIGN); 3087
3088 nskb = netdev_alloc_skb_ip_align(dev, skge->rx_buf_size);
3089 if (!nskb) 3089 if (!nskb)
3090 goto resubmit; 3090 goto resubmit;
3091 3091
3092 skb_reserve(nskb, NET_IP_ALIGN);
3093 pci_unmap_single(skge->hw->pdev, 3092 pci_unmap_single(skge->hw->pdev,
3094 pci_unmap_addr(e, mapaddr), 3093 pci_unmap_addr(e, mapaddr),
3095 pci_unmap_len(e, maplen), 3094 pci_unmap_len(e, maplen),