diff options
author | Jason Wright <jason@cvs.openbsd.org> | 1999-02-28 03:23:39 +0000 |
---|---|---|
committer | Jason Wright <jason@cvs.openbsd.org> | 1999-02-28 03:23:39 +0000 |
commit | 8b2014f291d209ff3ff452181dde5a2507e25963 (patch) | |
tree | 95438b5752ecc8ed381c9a1dfdcf7e343aa0a3a5 /sys/dev/ic | |
parent | 972131883b729aa5be397346b44e7f6e98a012a0 (diff) |
compensate for the test of packet ownership being moved to ether_input()
Diffstat (limited to 'sys/dev/ic')
-rw-r--r-- | sys/dev/ic/dp8390.c | 22 | ||||
-rw-r--r-- | sys/dev/ic/elink3.c | 18 | ||||
-rw-r--r-- | sys/dev/ic/smc91cxx.c | 16 |
3 files changed, 6 insertions, 50 deletions
diff --git a/sys/dev/ic/dp8390.c b/sys/dev/ic/dp8390.c index 2df1fea5ad3..49e9d6d9051 100644 --- a/sys/dev/ic/dp8390.c +++ b/sys/dev/ic/dp8390.c @@ -1,4 +1,4 @@ -/* $OpenBSD: dp8390.c,v 1.1 1998/09/22 06:41:12 fgsch Exp $ */ +/* $OpenBSD: dp8390.c,v 1.2 1999/02/28 03:23:36 jason Exp $ */ /* $NetBSD: dp8390.c,v 1.13 1998/07/05 06:49:11 jonathan Exp $ */ /* @@ -1000,26 +1000,8 @@ dp8390_read(sc, buf, len) * Check if there's a BPF listener on this interface. * If so, hand off the raw packet to bpf. */ - if (ifp->if_bpf) { + if (ifp->if_bpf) bpf_mtap(ifp->if_bpf, m); - - /* - * Note that the interface cannot be in promiscuous mode if - * there are no BPF listeners. And if we are in promiscuous - * mode, we have to check if this packet is really ours. - */ - if ((ifp->if_flags & IFF_PROMISC) && - (eh->ether_dhost[0] & 1) == 0 && /* !mcast and !bcast */ -#ifdef __NetBSD__ - bcmp(eh->ether_dhost, LLADDR(ifp->if_sadl), -#else - bcmp(eh->ether_dhost, sc->sc_arpcom.ac_enaddr, -#endif - sizeof(eh->ether_dhost)) != 0) { - m_freem(m); - return; - } - } #endif /* Fix up data start offset in mbuf to point past ether header. */ diff --git a/sys/dev/ic/elink3.c b/sys/dev/ic/elink3.c index 247bd81b98c..c8b52d4bf67 100644 --- a/sys/dev/ic/elink3.c +++ b/sys/dev/ic/elink3.c @@ -1,4 +1,4 @@ -/* $OpenBSD: elink3.c,v 1.30 1998/12/26 23:58:33 niklas Exp $ */ +/* $OpenBSD: elink3.c,v 1.31 1999/02/28 03:23:36 jason Exp $ */ /* $NetBSD: elink3.c,v 1.32 1997/05/14 00:22:00 thorpej Exp $ */ /* @@ -1163,22 +1163,8 @@ again: * Check if there's a BPF listener on this interface. * If so, hand off the raw packet to BPF. */ - if (ifp->if_bpf) { + if (ifp->if_bpf) bpf_mtap(ifp->if_bpf, m); - - /* - * Note that the interface cannot be in promiscuous mode if - * there are no BPF listeners. And if we are in promiscuous - * mode, we have to check if this packet is really ours. - */ - if ((ifp->if_flags & IFF_PROMISC) && - (eh->ether_dhost[0] & 1) == 0 && /* !mcast and !bcast */ - bcmp(eh->ether_dhost, sc->sc_arpcom.ac_enaddr, - sizeof(eh->ether_dhost)) != 0) { - m_freem(m); - return; - } - } #endif /* We assume the header fit entirely in one mbuf. */ diff --git a/sys/dev/ic/smc91cxx.c b/sys/dev/ic/smc91cxx.c index a423c51c9e9..8878c3b4055 100644 --- a/sys/dev/ic/smc91cxx.c +++ b/sys/dev/ic/smc91cxx.c @@ -1,4 +1,4 @@ -/* $OpenBSD: smc91cxx.c,v 1.2 1998/09/12 07:48:07 fgsch Exp $ */ +/* $OpenBSD: smc91cxx.c,v 1.3 1999/02/28 03:23:37 jason Exp $ */ /* $NetBSD: smc91cxx.c,v 1.11 1998/08/08 23:51:41 mycroft Exp $ */ /*- @@ -991,20 +991,8 @@ smc91cxx_read(sc) * Hand the packet off to bpf listeners. If there's a bpf listener, * we need to check if the packet is ours. */ - if (ifp->if_bpf) { + if (ifp->if_bpf) bpf_mtap(ifp->if_bpf, m); - - if ((ifp->if_flags & IFF_PROMISC) && - (eh->ether_dhost[0] & 1) == 0 && /* !mcast and !bcast */ -#ifdef __NetBSD__ - ether_cmp(eh->ether_dhost, LLADDR(ifp->if_sadl))) { -#else - ether_cmp(eh->ether_dhost, sc->sc_arpcom.ac_enaddr)) { -#endif - m_freem(m); - goto out; - } - } #endif /* |