diff --git a/sys/dev/pdq/pdq_ifsubr.c b/sys/dev/pdq/pdq_ifsubr.c index b359b5253456..50619cbe0242 100644 --- a/sys/dev/pdq/pdq_ifsubr.c +++ b/sys/dev/pdq/pdq_ifsubr.c @@ -229,7 +229,7 @@ pdq_os_receive_pdu( struct ifnet *ifp = PDQ_IFNET(sc); struct fddi_header *fh; - ifp->if_ipackets++; + if_inc_counter(ifp, IFCOUNTER_IPACKETS, 1); #if defined(PDQ_BUS_DMA) { /* @@ -251,8 +251,8 @@ pdq_os_receive_pdu( m->m_pkthdr.len = pktlen; fh = mtod(m, struct fddi_header *); if (drop || (fh->fddi_fc & (FDDIFC_L|FDDIFC_F)) != FDDIFC_LLC_ASYNC) { - ifp->if_iqdrops++; - ifp->if_ierrors++; + if_inc_counter(ifp, IFCOUNTER_IQDROPS, 1); + if_inc_counter(ifp, IFCOUNTER_IERRORS, 1); PDQ_OS_DATABUF_FREE(pdq, m); return; } @@ -289,7 +289,7 @@ pdq_os_transmit_done( PDQ_BPF_MTAP(sc, m); #endif PDQ_OS_DATABUF_FREE(pdq, m); - PDQ_IFNET(sc)->if_opackets++; + if_inc_counter(PDQ_IFNET(sc), IFCOUNTER_OPACKETS, 1); } void