summaryrefslogtreecommitdiffstats
path: root/net/bridge/br_notify.c
diff options
context:
space:
mode:
authorstephen hemminger <shemminger@vyatta.com>2012-12-28 18:15:22 +0000
committerDavid S. Miller <davem@davemloft.net>2012-12-30 02:31:43 -0800
commit576eb62598f10c8c7fd75703fe89010cdcfff596 (patch)
tree47317f7bc68dc06ad06735eb7c9ba4e271dcd793 /net/bridge/br_notify.c
parentaa1113d9f85da59dcbdd32aeb5d71da566e46def (diff)
downloadlinux-576eb62598f10c8c7fd75703fe89010cdcfff596.tar.bz2
bridge: respect RFC2863 operational state
The bridge link detection should follow the operational state of the lower device, rather than the carrier bit. This allows devices like tunnels that are controlled by userspace control plane to work with bridge STP link management. Signed-off-by: Stephen Hemminger <shemminger@vyatta.com> Reviewed-by: Flavio Leitner <fbl@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/bridge/br_notify.c')
-rw-r--r--net/bridge/br_notify.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/bridge/br_notify.c b/net/bridge/br_notify.c
index a76b62135558..1644b3e1f947 100644
--- a/net/bridge/br_notify.c
+++ b/net/bridge/br_notify.c
@@ -82,7 +82,7 @@ static int br_device_event(struct notifier_block *unused, unsigned long event, v
break;
case NETDEV_UP:
- if (netif_carrier_ok(dev) && (br->dev->flags & IFF_UP)) {
+ if (netif_running(br->dev) && netif_oper_up(dev)) {
spin_lock_bh(&br->lock);
br_stp_enable_port(p);
spin_unlock_bh(&br->lock);