patch-2.3.6 linux/drivers/net/3c515.c

Next file: linux/drivers/net/Config.in
Previous file: linux/drivers/misc/parport_share.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.3.5/linux/drivers/net/3c515.c linux/drivers/net/3c515.c
@@ -1009,6 +1009,7 @@
 			outb(0x00, ioaddr + TxStatus); /* Pop the status stack. */
 		}
 	}
+	vp->stats.tx_bytes+=skb->len;
 	return 0;
 }
 
@@ -1209,6 +1210,7 @@
 				netif_rx(skb);
 				dev->last_rx = jiffies;
 				vp->stats.rx_packets++;
+				vp->stats.rx_bytes+=skb->len;
 				/* Wait a limited time to go to next packet. */
 				for (i = 200; i >= 0; i--)
 					if ( ! (inw(ioaddr + EL3_STATUS) & CmdInProgress))
@@ -1256,6 +1258,7 @@
 			short pkt_len = rx_status & 0x1fff;
 			struct sk_buff *skb;
 
+			vp->stats.rx_bytes+=pkt_len;
 			if (vortex_debug > 4)
 				printk("Receiving packet size %d status %4.4x.\n",
 					   pkt_len, rx_status);

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)