summaryrefslogtreecommitdiffstats
path: root/sys/mips/cavium/octe
diff options
context:
space:
mode:
authorjmallett <jmallett@FreeBSD.org>2011-01-10 22:14:30 +0000
committerjmallett <jmallett@FreeBSD.org>2011-01-10 22:14:30 +0000
commitd4de086c11833121ebdf4ae6ef54a9bf4ece0f9e (patch)
treecb03813e6d1b6d18e57c0ac4c0e7dfc5a2087fc7 /sys/mips/cavium/octe
parent73877a6f553658a6cfe74817a182a5470b5990a7 (diff)
downloadFreeBSD-src-d4de086c11833121ebdf4ae6ef54a9bf4ece0f9e.zip
FreeBSD-src-d4de086c11833121ebdf4ae6ef54a9bf4ece0f9e.tar.gz
Count output bytes and packets.
Diffstat (limited to 'sys/mips/cavium/octe')
-rw-r--r--sys/mips/cavium/octe/ethernet-tx.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/sys/mips/cavium/octe/ethernet-tx.c b/sys/mips/cavium/octe/ethernet-tx.c
index 887d771..7ef77b5 100644
--- a/sys/mips/cavium/octe/ethernet-tx.c
+++ b/sys/mips/cavium/octe/ethernet-tx.c
@@ -247,6 +247,9 @@ int cvm_oct_xmit(struct mbuf *m, struct ifnet *ifp)
/* Pass it to any BPF listeners. */
ETHER_BPF_MTAP(ifp, m);
+
+ ifp->if_opackets++;
+ ifp->if_obytes += m->m_pkthdr.len;
}
/* Free mbufs not in use by the hardware */
OpenPOWER on IntegriCloud