diff options
author | Martin Pieuchot <mpi@cvs.openbsd.org> | 2015-09-09 12:50:09 +0000 |
---|---|---|
committer | Martin Pieuchot <mpi@cvs.openbsd.org> | 2015-09-09 12:50:09 +0000 |
commit | 3b1296e0133fa3343370fb3ba6504ba591aceb1c (patch) | |
tree | 5fd851dceece569c9e75558e439aecd5380ecd26 /sys/netinet6/raw_ip6.c | |
parent | d0ec26381c5e23ce70cda736a6e1b0f8cf7d30df (diff) |
Kill a couple of if_get()s only needed to increment per-ifp IPv6 stats.
We do not export those per-ifp statistics and they will soon all die.
"We're putting inet6 on a diet" claudio@
ok dlg@, mikeb@, claudio@
Diffstat (limited to 'sys/netinet6/raw_ip6.c')
-rw-r--r-- | sys/netinet6/raw_ip6.c | 14 |
1 files changed, 4 insertions, 10 deletions
diff --git a/sys/netinet6/raw_ip6.c b/sys/netinet6/raw_ip6.c index c3912e764f9..f207919159f 100644 --- a/sys/netinet6/raw_ip6.c +++ b/sys/netinet6/raw_ip6.c @@ -1,4 +1,4 @@ -/* $OpenBSD: raw_ip6.c,v 1.79 2015/07/28 12:22:07 bluhm Exp $ */ +/* $OpenBSD: raw_ip6.c,v 1.80 2015/09/09 12:50:08 mpi Exp $ */ /* $KAME: raw_ip6.c,v 1.69 2001/03/04 15:55:44 itojun Exp $ */ /* @@ -224,15 +224,9 @@ rip6_input(struct mbuf **mp, int *offp, int proto) m_freem(m); else { u_int8_t *prvnxtp = ip6_get_prevhdr(m, *offp); /* XXX */ - struct ifnet *ifp; - - ifp = if_get(m->m_pkthdr.ph_ifidx); - if (ifp != NULL) { - in6_ifstat_inc(ifp, ifs6_in_protounknown); - icmp6_error(m, ICMP6_PARAM_PROB, - ICMP6_PARAMPROB_NEXTHEADER, - prvnxtp - mtod(m, u_int8_t *)); - } + icmp6_error(m, ICMP6_PARAM_PROB, + ICMP6_PARAMPROB_NEXTHEADER, + prvnxtp - mtod(m, u_int8_t *)); } ip6stat.ip6s_delivered--; } |