From: Stephen Hemminger Date: Fri, 16 Feb 2007 00:40:34 +0000 (-0800) Subject: sky2: receive error handling improvements X-Git-Tag: v2.6.21-rc1~74^2~16 X-Git-Url: http://pilppa.com/gitweb/?a=commitdiff_plain;h=a79abdc6eeca745b2af04fc03f9a04da0d294094;p=linux-2.6-omap-h63xx.git sky2: receive error handling improvements Don't drop oversize frame it might be a VLAN (untagged). Use different counter for fifo overrun vs fifo error. Print error on fifo overrrun. Signed-off-by: Stephen Hemminger Signed-off-by: Jeff Garzik --- diff --git a/drivers/net/sky2.c b/drivers/net/sky2.c index fafa4021bb8..c058117d2a6 100644 --- a/drivers/net/sky2.c +++ b/drivers/net/sky2.c @@ -2056,9 +2056,6 @@ static struct sk_buff *sky2_receive(struct net_device *dev, if (!(status & GMR_FS_RX_OK)) goto resubmit; - if (length > dev->mtu + ETH_HLEN) - goto oversize; - if (length < copybreak) skb = receive_copy(sky2, re, length); else @@ -2068,14 +2065,10 @@ resubmit: return skb; -oversize: - ++sky2->net_stats.rx_over_errors; - goto resubmit; - error: ++sky2->net_stats.rx_errors; if (status & GMR_FS_RX_FF_OV) { - sky2->net_stats.rx_fifo_errors++; + sky2->net_stats.rx_over_errors++; goto resubmit; }