diff options
author | stephen hemminger <shemminger@vyatta.com> | 2010-11-15 09:38:13 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-11-15 22:13:17 +0300 |
commit | b5ed54e94d324f17c97852296d61a143f01b227a (patch) | |
tree | 2104d3cde24efc1145bc71beb4b61d79ed841132 /net/bridge/br_notify.c | |
parent | 61391cde9eefac5cfcf6d214aa80c77e58b1626b (diff) | |
download | linux-b5ed54e94d324f17c97852296d61a143f01b227a.tar.xz |
bridge: fix RCU races with bridge port
The macro br_port_exists() is not enough protection when only
RCU is being used. There is a tiny race where other CPU has cleared port
handler hook, but is bridge port flag might still be set.
Signed-off-by: Stephen Hemminger <shemminger@vyatta.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.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/bridge/br_notify.c b/net/bridge/br_notify.c index 404d4e14c6a7..ef2175c8b91d 100644 --- a/net/bridge/br_notify.c +++ b/net/bridge/br_notify.c @@ -32,7 +32,7 @@ struct notifier_block br_device_notifier = { static int br_device_event(struct notifier_block *unused, unsigned long event, void *ptr) { struct net_device *dev = ptr; - struct net_bridge_port *p = br_port_get(dev); + struct net_bridge_port *p; struct net_bridge *br; int err; |