diff options
Diffstat (limited to 'drivers/net/ibm_newemac')
-rw-r--r-- | drivers/net/ibm_newemac/core.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/net/ibm_newemac/core.c b/drivers/net/ibm_newemac/core.c index ed24a1d607dd..61af02b4c9d8 100644 --- a/drivers/net/ibm_newemac/core.c +++ b/drivers/net/ibm_newemac/core.c | |||
@@ -1643,6 +1643,12 @@ static int emac_poll_rx(void *param, int budget) | |||
1643 | goto next; | 1643 | goto next; |
1644 | } | 1644 | } |
1645 | 1645 | ||
1646 | if (len < ETH_HLEN) { | ||
1647 | ++dev->estats.rx_dropped_stack; | ||
1648 | emac_recycle_rx_skb(dev, slot, len); | ||
1649 | goto next; | ||
1650 | } | ||
1651 | |||
1646 | if (len && len < EMAC_RX_COPY_THRESH) { | 1652 | if (len && len < EMAC_RX_COPY_THRESH) { |
1647 | struct sk_buff *copy_skb = | 1653 | struct sk_buff *copy_skb = |
1648 | alloc_skb(len + EMAC_RX_SKB_HEADROOM + 2, GFP_ATOMIC); | 1654 | alloc_skb(len + EMAC_RX_SKB_HEADROOM + 2, GFP_ATOMIC); |
@@ -2738,6 +2744,8 @@ static int __devinit emac_probe(struct of_device *ofdev, | |||
2738 | /* Clean rings */ | 2744 | /* Clean rings */ |
2739 | memset(dev->tx_desc, 0, NUM_TX_BUFF * sizeof(struct mal_descriptor)); | 2745 | memset(dev->tx_desc, 0, NUM_TX_BUFF * sizeof(struct mal_descriptor)); |
2740 | memset(dev->rx_desc, 0, NUM_RX_BUFF * sizeof(struct mal_descriptor)); | 2746 | memset(dev->rx_desc, 0, NUM_RX_BUFF * sizeof(struct mal_descriptor)); |
2747 | memset(dev->tx_skb, 0, NUM_TX_BUFF * sizeof(struct sk_buff *)); | ||
2748 | memset(dev->rx_skb, 0, NUM_RX_BUFF * sizeof(struct sk_buff *)); | ||
2741 | 2749 | ||
2742 | /* Attach to ZMII, if needed */ | 2750 | /* Attach to ZMII, if needed */ |
2743 | if (emac_has_feature(dev, EMAC_FTR_HAS_ZMII) && | 2751 | if (emac_has_feature(dev, EMAC_FTR_HAS_ZMII) && |