diff options
author | Takashi Iwai <tiwai@suse.de> | 2011-04-05 09:12:21 +0200 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2011-04-05 09:12:21 +0200 |
commit | 4e29402fe4b2006c994eed5020c42b2cc87d9b42 (patch) | |
tree | c0229c107045ab21487729f6a6cab6b70ed30bfa /net/bridge/br_stp_if.c | |
parent | f8852b12200df393b0a4db1a7052454bbc335443 (diff) | |
parent | 00b317a41c5428b13eb7e5b4bbc691b1aa7afa80 (diff) |
Merge branch 'for-2.6.39' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound-2.6 into fix/asoc
Diffstat (limited to 'net/bridge/br_stp_if.c')
-rw-r--r-- | net/bridge/br_stp_if.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/net/bridge/br_stp_if.c b/net/bridge/br_stp_if.c index 79372d4a4055..5593f5aec942 100644 --- a/net/bridge/br_stp_if.c +++ b/net/bridge/br_stp_if.c @@ -204,7 +204,7 @@ void br_stp_change_bridge_id(struct net_bridge *br, const unsigned char *addr) static const unsigned short br_mac_zero_aligned[ETH_ALEN >> 1]; /* called under bridge lock */ -void br_stp_recalculate_bridge_id(struct net_bridge *br) +bool br_stp_recalculate_bridge_id(struct net_bridge *br) { const unsigned char *br_mac_zero = (const unsigned char *)br_mac_zero_aligned; @@ -222,8 +222,11 @@ void br_stp_recalculate_bridge_id(struct net_bridge *br) } - if (compare_ether_addr(br->bridge_id.addr, addr)) - br_stp_change_bridge_id(br, addr); + if (compare_ether_addr(br->bridge_id.addr, addr) == 0) + return false; /* no change */ + + br_stp_change_bridge_id(br, addr); + return true; } /* called under bridge lock */ |