diff options
Diffstat (limited to 'sys')
-rw-r--r-- | sys/modules/if_gre/Makefile | 7 | ||||
-rw-r--r-- | sys/net/if_gre.c | 9 | ||||
-rw-r--r-- | sys/netinet/ip_gre.c | 9 |
3 files changed, 3 insertions, 22 deletions
diff --git a/sys/modules/if_gre/Makefile b/sys/modules/if_gre/Makefile index 5ef40ca..9079ef9 100644 --- a/sys/modules/if_gre/Makefile +++ b/sys/modules/if_gre/Makefile @@ -3,9 +3,7 @@ .PATH: ${.CURDIR}/../../net ${.CURDIR}/../../netinet KMOD= if_gre -SRCS= if_gre.c ip_gre.c opt_inet.h opt_ns.h opt_atalk.h bpf.h - -CLEANFILES+=bpf.h +SRCS= if_gre.c ip_gre.c opt_inet.h opt_ns.h opt_atalk.h opt_inet.h: echo "#define INET 1" > ${.TARGET} @@ -16,7 +14,4 @@ opt_ns.h: opt_atalk.h: echo "#define NETATALK 1" > ${.TARGET} -bpf.h: - echo "#define NBPF 1" > ${.TARGET} - .include <bsd.kmod.mk> diff --git a/sys/net/if_gre.c b/sys/net/if_gre.c index cdce71692..dfa9ddb 100644 --- a/sys/net/if_gre.c +++ b/sys/net/if_gre.c @@ -49,7 +49,6 @@ #include "opt_atalk.h" #include "opt_inet.h" #include "opt_ns.h" -#include "bpf.h" #include <sys/param.h> #include <sys/kernel.h> @@ -78,9 +77,7 @@ #error "Huh? if_gre without inet?" #endif -#if NBPF > 0 #include <net/bpf.h> -#endif #include <net/net_osdep.h> #include <net/if_gre.h> @@ -183,9 +180,7 @@ gre_clone_create(ifc, unit) sc->encap = NULL; sc->called = 0; if_attach(&sc->sc_if); -#if NBPF bpfattach(&sc->sc_if, DLT_NULL, sizeof(u_int32_t)); -#endif LIST_INSERT_HEAD(&gre_softc_list, sc, sc_list); return (0); } @@ -201,9 +196,7 @@ gre_clone_destroy(ifp) encap_detach(sc->encap); #endif LIST_REMOVE(sc, sc_list); -#if NBPF bpfdetach(ifp); -#endif if_detach(ifp); free(sc, M_GRE); } @@ -247,7 +240,6 @@ gre_output(struct ifnet *ifp, struct mbuf *m, struct sockaddr *dst, ip = NULL; osrc = 0; -#if NBPF if (ifp->if_bpf) { /* see comment of other if_foo.c files */ struct mbuf m0; @@ -259,7 +251,6 @@ gre_output(struct ifnet *ifp, struct mbuf *m, struct sockaddr *dst, bpf_mtap(ifp, &m0); } -#endif m->m_flags &= ~(M_BCAST|M_MCAST); diff --git a/sys/netinet/ip_gre.c b/sys/netinet/ip_gre.c index 93afaa3..ac28b6e 100644 --- a/sys/netinet/ip_gre.c +++ b/sys/netinet/ip_gre.c @@ -46,7 +46,6 @@ #include "opt_inet.h" #include "opt_ns.h" #include "opt_atalk.h" -#include "bpf.h" #include <sys/param.h> #include <sys/systm.h> @@ -209,7 +208,6 @@ gre_input2(struct mbuf *m ,int hlen, u_char proto) m->m_len -= hlen; m->m_pkthdr.len -= hlen; -#if NBPF > 0 if (sc->sc_if.if_bpf) { struct mbuf m0; u_int32_t af = AF_INET; @@ -219,8 +217,7 @@ gre_input2(struct mbuf *m ,int hlen, u_char proto) m0.m_data = (char *)⁡ bpf_mtap(&(sc->sc_if), &m0); - } -#endif /*NBPF > 0*/ + } m->m_pkthdr.rcvif = &sc->sc_if; @@ -306,7 +303,6 @@ gre_mobile_input(m, va_alist) ip->ip_sum = 0; ip->ip_sum = in_cksum(m, (ip->ip_hl << 2)); -#if NBPF > 0 if (sc->sc_if.if_bpf) { struct mbuf m0; u_int af = AF_INET; @@ -316,8 +312,7 @@ gre_mobile_input(m, va_alist) m0.m_data = (char *)⁡ bpf_mtap(&(sc->sc_if), &m0); - } -#endif /*NBPFILTER > 0*/ + } m->m_pkthdr.rcvif = &sc->sc_if; |