summaryrefslogtreecommitdiffstats
path: root/sys
diff options
context:
space:
mode:
authorthompsa <thompsa@FreeBSD.org>2007-05-20 03:21:59 +0000
committerthompsa <thompsa@FreeBSD.org>2007-05-20 03:21:59 +0000
commit6dcb39daa0ee5b752652ea7b5034853f8290aef3 (patch)
tree64ca74add3d061a6440b4070678e13a491738714 /sys
parent9e72cd22f41681960e9c998248ffb2b1658d6252 (diff)
downloadFreeBSD-src-6dcb39daa0ee5b752652ea7b5034853f8290aef3.zip
FreeBSD-src-6dcb39daa0ee5b752652ea7b5034853f8290aef3.tar.gz
- packets on the input interface were counted twice
- Use IFQ_HANDOFF instead of rolling our own
Diffstat (limited to 'sys')
-rw-r--r--sys/net/if_lagg.c14
1 files changed, 1 insertions, 13 deletions
diff --git a/sys/net/if_lagg.c b/sys/net/if_lagg.c
index 02fed5e..1ea11236 100644
--- a/sys/net/if_lagg.c
+++ b/sys/net/if_lagg.c
@@ -1078,8 +1078,6 @@ lagg_input(struct ifnet *ifp, struct mbuf *m)
m = (*sc->sc_input)(sc, lp, m);
if (m != NULL) {
- ifp->if_ipackets++;
- ifp->if_ibytes += m->m_pkthdr.len;
trifp->if_ipackets++;
trifp->if_ibytes += m->m_pkthdr.len;
}
@@ -1271,17 +1269,7 @@ lagg_enqueue(struct ifnet *ifp, struct mbuf *m)
{
int error = 0;
- /* Send mbuf */
- IFQ_ENQUEUE(&ifp->if_snd, m, error);
- if (error)
- return (error);
- if ((ifp->if_drv_flags & IFF_DRV_OACTIVE) == 0)
- (*ifp->if_start)(ifp);
-
- ifp->if_obytes += m->m_pkthdr.len;
- if (m->m_flags & M_MCAST)
- ifp->if_omcasts++;
-
+ IFQ_HANDOFF(ifp, m, error);
return (error);
}
OpenPOWER on IntegriCloud