patch-2.2.0-pre3 linux/drivers/net/epic100.c
Next file: linux/drivers/net/sdla_x25.c
Previous file: linux/drivers/net/3c501.c
Back to the patch index
Back to the overall index
- Lines: 19
- Date:
Thu Dec 31 12:05:12 1998
- Orig file:
v2.2.0-pre2/linux/drivers/net/epic100.c
- Orig date:
Tue Dec 22 14:16:55 1998
diff -u --recursive --new-file v2.2.0-pre2/linux/drivers/net/epic100.c linux/drivers/net/epic100.c
@@ -884,6 +884,9 @@
ep->tx_ring[entry].bufaddr = virt_to_bus(skb->data);
ep->tx_ring[entry].buflength = skb->len;
+ /* tx_bytes counting -- Nolan Leake */
+ ep->stats.tx_bytes += ep->tx_ring[entry].txlength;
+
if (ep->cur_tx - ep->dirty_tx < TX_RING_SIZE/2) {/* Typical path */
flag = 0x10; /* No interrupt */
clear_bit(0, (void*)&dev->tbusy);
@@ -1112,6 +1115,8 @@
skb->protocol = eth_type_trans(skb, dev);
netif_rx(skb);
ep->stats.rx_packets++;
+ /* rx_bytes counting -- Nolan Leake */
+ ep->stats.rx_bytes += pkt_len;
}
work_done++;
entry = (++ep->cur_rx) % RX_RING_SIZE;
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov