netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* bridge: accept bridge own MAC address as local
@ 2011-08-12 11:30 Ulrich Weber
  2011-08-12 16:19 ` Stephen Hemminger
  2011-08-26 16:29 ` David Miller
  0 siblings, 2 replies; 5+ messages in thread
From: Ulrich Weber @ 2011-08-12 11:30 UTC (permalink / raw)
  To: davem; +Cc: netdev

bridge: accept bridge own MAC address as local
if MAC address of bridge is manually set (BR_SET_MAC_ADDR). Otherwise
only MAC addresses of bridge members will work if manually set.

Signed-off-by: Ulrich Weber <ulrich.weber@sophos.com>
---
 net/bridge/br_input.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/net/bridge/br_input.c b/net/bridge/br_input.c
index f06ee39..3adabe3 100644
--- a/net/bridge/br_input.c
+++ b/net/bridge/br_input.c
@@ -93,7 +93,9 @@ int br_handle_frame_finish(struct sk_buff *skb)
 			skb2 = skb;
 
 		br->dev->stats.multicast++;
-	} else if ((dst = __br_fdb_get(br, dest)) && dst->is_local) {
+	} else if ((br->flags & BR_SET_MAC_ADDR &&
+		    !compare_ether_addr(br->bridge_id.addr, dest)) ||
+		   ((dst = __br_fdb_get(br, dest)) && dst->is_local)) {
 		skb2 = skb;
 		/* Do not forward the packet since it's local. */
 		skb = NULL;
-- 
1.7.4.1


^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2011-08-26 16:42 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-08-12 11:30 bridge: accept bridge own MAC address as local Ulrich Weber
2011-08-12 16:19 ` Stephen Hemminger
2011-08-12 16:36   ` Ulrich Weber
2011-08-26 16:29 ` David Miller
2011-08-26 16:42   ` Stephen Hemminger

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).