patch-2.4.3 linux/drivers/net/ewrk3.c
Next file: linux/drivers/net/fc/iph5526.c
Previous file: linux/drivers/net/eth16i.c
Back to the patch index
Back to the overall index
-  Lines: 40
-  Date:
Sat Mar  3 10:55:48 2001
-  Orig file: 
v2.4.2/linux/drivers/net/ewrk3.c
-  Orig date: 
Wed Feb 21 18:20:26 2001
diff -u --recursive --new-file v2.4.2/linux/drivers/net/ewrk3.c linux/drivers/net/ewrk3.c
@@ -997,19 +997,6 @@
 							isa_memcpy_fromio(p, buf, pkt_len);
 						}
 
-						/*
-						   ** Notify the upper protocol layers that there is another
-						   ** packet to handle
-						 */
-						skb->protocol = eth_type_trans(skb, dev);
-						netif_rx(skb);
-
-						/*
-						   ** Update stats
-						 */
-						dev->last_rx = jiffies;
-						lp->stats.rx_packets++;
-						lp->stats.rx_bytes += pkt_len;
 						for (i = 1; i < EWRK3_PKT_STAT_SZ - 1; i++) {
 							if (pkt_len < i * EWRK3_PKT_BIN_SZ) {
 								lp->pktStats.bins[i]++;
@@ -1031,6 +1018,19 @@
 						if (lp->pktStats.bins[0] == 0) {	/* Reset counters */
 							memset(&lp->pktStats, 0, sizeof(lp->pktStats));
 						}
+						/*
+						   ** Notify the upper protocol layers that there is another
+						   ** packet to handle
+						 */
+						skb->protocol = eth_type_trans(skb, dev);
+						netif_rx(skb);
+
+						/*
+						   ** Update stats
+						 */
+						dev->last_rx = jiffies;
+						lp->stats.rx_packets++;
+						lp->stats.rx_bytes += pkt_len;
 					} else {
 						printk("%s: Insufficient memory; nuking packet.\n", dev->name);
 						lp->stats.rx_dropped++;		/* Really, deferred. */
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)