diff options
author | Herbert Xu <herbert@gondor.apana.org.au> | 2010-03-05 21:03:35 +0000 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-03-07 15:31:12 -0800 |
commit | 10cc2b50eb4b01ca4dc014af2094d28b4ebe20d7 (patch) | |
tree | 3e9278a4dda2bd8ccb7e37ddf14344444834c0f7 /net/bridge | |
parent | 49f5fcfd4ac3df24aa66520e1c5f37db5dfa8c10 (diff) |
bridge: Fix RCU race in br_multicast_stop
Thanks to Paul McKenny for pointing out that it is incorrect to use
synchronize_rcu_bh to ensure that pending callbacks have completed.
Instead we should use rcu_barrier_bh.
Reported-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/bridge')
-rw-r--r-- | net/bridge/br_multicast.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/bridge/br_multicast.c b/net/bridge/br_multicast.c index a1ffe1582c9a..12ce1eaa4f3e 100644 --- a/net/bridge/br_multicast.c +++ b/net/bridge/br_multicast.c @@ -1135,7 +1135,7 @@ void br_multicast_stop(struct net_bridge *br) if (mdb->old) { spin_unlock_bh(&br->multicast_lock); - synchronize_rcu_bh(); + rcu_barrier_bh(); spin_lock_bh(&br->multicast_lock); WARN_ON(mdb->old); } |