diff options
author | phk <phk@FreeBSD.org> | 1999-09-25 12:06:01 +0000 |
---|---|---|
committer | phk <phk@FreeBSD.org> | 1999-09-25 12:06:01 +0000 |
commit | d612df1de637eabac588385f0ef90f8d91a297de (patch) | |
tree | 98ecfb3ce51180cb27c6f26afbbda3e06f598865 /sys/i386/isa/if_le.c | |
parent | 5f4944fbfdbe191d7f3f19a522957a406819ad3b (diff) | |
download | FreeBSD-src-d612df1de637eabac588385f0ef90f8d91a297de.zip FreeBSD-src-d612df1de637eabac588385f0ef90f8d91a297de.tar.gz |
Remove NBPF conditionality of bpf calls in most of our network drivers.
This means that we will not have to have a bpf and a non-bpf version
of our driver modules.
This does not open any security hole, because the bpf core isn't loadable
The drivers left unchanged are the "cross platform" drivers where the respective
maintainers are urged to DTRT, whatever that may be.
Add a couple of missing FreeBSD tags.
Diffstat (limited to 'sys/i386/isa/if_le.c')
-rw-r--r-- | sys/i386/isa/if_le.c | 11 |
1 files changed, 0 insertions, 11 deletions
diff --git a/sys/i386/isa/if_le.c b/sys/i386/isa/if_le.c index 700cb6d..6206495 100644 --- a/sys/i386/isa/if_le.c +++ b/sys/i386/isa/if_le.c @@ -56,7 +56,6 @@ #include <netinet/in.h> #include <netinet/if_ether.h> -#include "bpf.h" #include <machine/clock.h> @@ -66,9 +65,7 @@ #include <vm/vm.h> #include <vm/pmap.h> -#if NBPF > 0 #include <net/bpf.h> -#endif /* Forward declarations */ typedef struct le_softc le_softc_t; @@ -359,9 +356,7 @@ le_attach( ifp->if_addrlen = 6; ifp->if_hdrlen = 14; -#if NBPF > 0 bpfattach(ifp, DLT_EN10MB, sizeof(struct ether_header)); -#endif if_attach(ifp); ether_ifattach(ifp); @@ -401,7 +396,6 @@ le_input( } MEMCPY(&eh, seg1, sizeof(eh)); -#if NBPF > 0 if (sc->le_if.if_bpf != NULL && seg2 == NULL) { bpf_tap(&sc->le_if, seg1, total_len); /* @@ -423,7 +417,6 @@ le_input( } } } -#endif seg1 += sizeof(eh); total_len -= sizeof(eh); len1 -= sizeof(eh); MGETHDR(m, M_DONTWAIT, MT_DATA); @@ -458,7 +451,6 @@ le_input( MEMCPY(mtod(m, caddr_t), seg1, len1); if (seg2 != NULL) MEMCPY(mtod(m, caddr_t) + len1, seg2, total_len - len1); -#if NBPF > 0 if (sc->le_if.if_bpf != NULL && seg2 != NULL) { bpf_mtap(&sc->le_if, m); /* @@ -483,7 +475,6 @@ le_input( } } } -#endif ether_input(&sc->le_if, &eh, m); } @@ -1077,10 +1068,8 @@ lemac_start( LE_OUTB(sc, LEMAC_REG_TQ, tx_pg); /* tell chip to transmit this packet */ -#if NBPF > 0 if (sc->le_if.if_bpf) bpf_mtap(&sc->le_if, m); -#endif m_freem(m); /* free the mbuf */ } |