From 165d81879ead70b028b140d76d9143aefee5ce16 Mon Sep 17 00:00:00 2001 From: wpaul Date: Thu, 23 Sep 1999 03:32:57 +0000 Subject: As suggested by phk, unconditionalize BPF support in these drivers. Since there are stubs compiled into the kernel if BPF support is not enabled, there aren't any problems with unresolved symbols. The modules in /modules are compiled with BPF support enabled anyway, so the most this will do is bloat GENERIC a little. --- sys/dev/vr/if_vr.c | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) (limited to 'sys/dev/vr') diff --git a/sys/dev/vr/if_vr.c b/sys/dev/vr/if_vr.c index af3ae7e..18e7bdf 100644 --- a/sys/dev/vr/if_vr.c +++ b/sys/dev/vr/if_vr.c @@ -59,8 +59,6 @@ * transmission. */ -#include "bpf.h" - #include #include #include @@ -75,9 +73,7 @@ #include #include -#if NBPF > 0 #include -#endif #include "opt_bdg.h" #ifdef BRIDGE @@ -810,9 +806,7 @@ static int vr_attach(dev) if_attach(ifp); ether_ifattach(ifp); -#if NBPF > 0 bpfattach(ifp, DLT_EN10MB, sizeof(struct ether_header)); -#endif fail: splx(s); @@ -1049,7 +1043,6 @@ static void vr_rxeof(sc) ifp->if_ipackets++; eh = mtod(m, struct ether_header *); -#if NBPF > 0 /* * Handle BPF listeners. Let the BPF user see the packet, but * don't pass it up to the ether_input() layer unless it's @@ -1066,7 +1059,7 @@ static void vr_rxeof(sc) continue; } } -#endif /* NBPF>0 */ + #ifdef BRIDGE if (do_bridge) { struct ifnet *bdg_ifp; @@ -1385,14 +1378,13 @@ static void vr_start(ifp) if (cur_tx != start_tx) VR_TXOWN(cur_tx) = VR_TXSTAT_OWN; -#if NBPF > 0 /* * If there's a BPF listener, bounce a copy of this frame * to him. */ if (ifp->if_bpf) bpf_mtap(ifp, cur_tx->vr_mbuf); -#endif + VR_TXOWN(cur_tx) = VR_TXSTAT_OWN; VR_SETBIT16(sc, VR_COMMAND, /*VR_CMD_TX_ON|*/VR_CMD_TX_GO); } -- cgit v1.1