aboutsummaryrefslogtreecommitdiff
path: root/sys/pci/if_sk.c
diff options
context:
space:
mode:
authorBill Paul <wpaul@FreeBSD.org>1999-09-23 03:32:57 +0000
committerBill Paul <wpaul@FreeBSD.org>1999-09-23 03:32:57 +0000
commit98a229f65ec2facdae1bd4377ace7ee991f74980 (patch)
treeda561a7a22c6b6534362666c4aa27f7211663f3f /sys/pci/if_sk.c
parent62e93e1c86164dd9e1542757f1148d9b321a072c (diff)
downloadsrc-98a229f65ec2facdae1bd4377ace7ee991f74980.tar.gz
src-98a229f65ec2facdae1bd4377ace7ee991f74980.zip
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.
Notes
Notes: svn path=/head/; revision=51583
Diffstat (limited to 'sys/pci/if_sk.c')
-rw-r--r--sys/pci/if_sk.c11
1 files changed, 1 insertions, 10 deletions
diff --git a/sys/pci/if_sk.c b/sys/pci/if_sk.c
index fdea86fcdf1e..95bf5403d67e 100644
--- a/sys/pci/if_sk.c
+++ b/sys/pci/if_sk.c
@@ -61,8 +61,6 @@
* both XMACs to operate as independent interfaces.
*/
-#include "bpf.h"
-
#include <sys/param.h>
#include <sys/systm.h>
#include <sys/sockio.h>
@@ -78,9 +76,7 @@
#include <net/if_dl.h>
#include <net/if_media.h>
-#if NBPF > 0
#include <net/bpf.h>
-#endif
#include <vm/vm.h> /* for vtophys */
#include <vm/pmap.h> /* for vtophys */
@@ -1150,9 +1146,7 @@ static int sk_attach_xmac(sc, port)
if_attach(ifp);
ether_ifattach(ifp);
-#if NBPF > 0
bpfattach(ifp, DLT_EN10MB, sizeof(struct ether_header));
-#endif
return(0);
}
@@ -1455,10 +1449,8 @@ static void sk_start(ifp)
* If there's a BPF listener, bounce a copy of this frame
* to him.
*/
-#if NBPF > 0
if (ifp->if_bpf)
bpf_mtap(ifp, m_head);
-#endif
}
/* Transmit */
@@ -1563,7 +1555,6 @@ static void sk_rxeof(sc_if)
ifp->if_ipackets++;
eh = mtod(m, struct ether_header *);
-#if NBPF > 0
if (ifp->if_bpf) {
bpf_mtap(ifp, m);
if (ifp->if_flags & IFF_PROMISC &&
@@ -1573,7 +1564,7 @@ static void sk_rxeof(sc_if)
continue;
}
}
-#endif
+
/* Remove header from mbuf and pass it on. */
m_adj(m, sizeof(struct ether_header));
ether_input(ifp, eh, m);