diff options
author | Jason Wright <jason@cvs.openbsd.org> | 1999-03-19 22:47:35 +0000 |
---|---|---|
committer | Jason Wright <jason@cvs.openbsd.org> | 1999-03-19 22:47:35 +0000 |
commit | 23e9862bcd1cec2160166d253b928b0f12e59f0a (patch) | |
tree | f24ce1be271e475b806f70f4a79026ceef8ee7ea /sys/net/if_bridge.c | |
parent | 4ea62010d0d178dc752f170c8b7bf5464c5df47f (diff) |
Add flag to allow some interfaces to not see packets with unknown destination.
Diffstat (limited to 'sys/net/if_bridge.c')
-rw-r--r-- | sys/net/if_bridge.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/sys/net/if_bridge.c b/sys/net/if_bridge.c index 9e3ed260c65..1038df0c081 100644 --- a/sys/net/if_bridge.c +++ b/sys/net/if_bridge.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_bridge.c,v 1.7 1999/03/19 02:46:54 jason Exp $ */ +/* $OpenBSD: if_bridge.c,v 1.8 1999/03/19 22:47:33 jason Exp $ */ /* * Copyright (c) 1999 Jason L. Wright (jason@thought.net) @@ -280,7 +280,7 @@ bridge_ioctl(ifp, cmd, data) } p->ifp = ifs; - p->bif_flags = IFBIF_LEARNING; + p->bif_flags = IFBIF_LEARNING | IFBIF_DISCOVER; LIST_INSERT_HEAD(&sc->sc_iflist, p, next); ifs->if_bridge = (caddr_t)sc; break; @@ -890,6 +890,10 @@ bridge_broadcast(sc, ifp, eh, m) if (p->ifp->if_index == ifp->if_index) continue; + if ((p->bif_flags & IFBIF_DISCOVER) == 0 && + (m->m_flags & (M_BCAST|M_MCAST)) == 0) + continue; + if ((p->ifp->if_flags & IFF_RUNNING) == 0) continue; |