summaryrefslogtreecommitdiffstats
path: root/sys/dev/wtap
diff options
context:
space:
mode:
authorglebius <glebius@FreeBSD.org>2014-09-19 03:51:26 +0000
committerglebius <glebius@FreeBSD.org>2014-09-19 03:51:26 +0000
commitb3b337a80e78f4cc2d0c75f98e4685bee9c749c9 (patch)
tree6899fa7510de1719ea0a76790446b61cd2d300fe /sys/dev/wtap
parent094cca2b36ac9809749d6a0b76bcd37556939c00 (diff)
downloadFreeBSD-src-b3b337a80e78f4cc2d0c75f98e4685bee9c749c9.zip
FreeBSD-src-b3b337a80e78f4cc2d0c75f98e4685bee9c749c9.tar.gz
Mechanically convert to if_inc_counter().
Diffstat (limited to 'sys/dev/wtap')
-rw-r--r--sys/dev/wtap/if_wtap.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/sys/dev/wtap/if_wtap.c b/sys/dev/wtap/if_wtap.c
index 6bc8e6b..3c64085 100644
--- a/sys/dev/wtap/if_wtap.c
+++ b/sys/dev/wtap/if_wtap.c
@@ -421,13 +421,13 @@ wtap_start(struct ifnet *ifp)
#endif
if ((m->m_flags & M_FRAG)){
printf("dont support frags\n");
- ifp->if_oerrors++;
+ if_inc_counter(ifp, IFCOUNTER_OERRORS, 1);
return;
}
- ifp->if_opackets++;
+ if_inc_counter(ifp, IFCOUNTER_OPACKETS, 1);
if(wtap_raw_xmit(ni, m, NULL) < 0){
printf("error raw_xmiting\n");
- ifp->if_oerrors++;
+ if_inc_counter(ifp, IFCOUNTER_OERRORS, 1);
return;
}
}
@@ -594,7 +594,7 @@ wtap_rx_deliver(struct wtap_softc *sc, struct mbuf *m)
if_printf(ifp, "%s: no mbuf!\n", __func__);
}
- ifp->if_ipackets++;
+ if_inc_counter(ifp, IFCOUNTER_IPACKETS, 1);
ieee80211_dump_pkt(ic, mtod(m, caddr_t), 0,0,0);
@@ -649,7 +649,7 @@ wtap_rx_proc(void *arg, int npending)
return;
}
- ifp->if_ipackets++;
+ if_inc_counter(ifp, IFCOUNTER_IPACKETS, 1);
#if 0
ieee80211_dump_pkt(ic, mtod(m, caddr_t), 0,0,0);
#endif
OpenPOWER on IntegriCloud