Mechanically convert to if_inc_counter().

This commit is contained in:
Gleb Smirnoff 2014-09-19 10:19:51 +00:00
parent 6ff8af1ca5
commit 32c7c51c2a
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=271863

View File

@ -142,8 +142,8 @@ gre_input2(struct mbuf *m ,int hlen, u_char proto)
}
gip = mtod(m, struct greip *);
GRE2IFP(sc)->if_ipackets++;
GRE2IFP(sc)->if_ibytes += m->m_pkthdr.len;
if_inc_counter(GRE2IFP(sc), IFCOUNTER_IPACKETS, 1);
if_inc_counter(GRE2IFP(sc), IFCOUNTER_IBYTES, m->m_pkthdr.len);
switch (proto) {
case IPPROTO_GRE:
@ -243,8 +243,8 @@ gre_mobile_input(struct mbuf **mp, int *offp, int proto)
ip = mtod(m, struct ip *);
mip = mtod(m, struct mobip_h *);
GRE2IFP(sc)->if_ipackets++;
GRE2IFP(sc)->if_ibytes += m->m_pkthdr.len;
if_inc_counter(GRE2IFP(sc), IFCOUNTER_IPACKETS, 1);
if_inc_counter(GRE2IFP(sc), IFCOUNTER_IBYTES, m->m_pkthdr.len);
if (ntohs(mip->mh.proto) & MOB_H_SBIT) {
msiz = MOB_H_SIZ_L;