aboutsummaryrefslogtreecommitdiffstats
path: root/net/mac80211/cfg.c
diff options
context:
space:
mode:
authorJohannes Berg <johannes@sipsolutions.net>2008-03-31 13:23:02 -0400
committerJohn W. Linville <linville@tuxdriver.com>2008-04-01 17:14:10 -0400
commit4f6fab472c4c7c21d577f85fabec7628d4a05637 (patch)
tree0949dffadb0b715053e4d7148ebcabe930b39361 /net/mac80211/cfg.c
parent93e5deb1ae39b56f4743955e76c72251256f23c1 (diff)
mac80211: clean up sta_info_destroy() users wrt. RCU/locking
Calling sta_info_destroy() doesn't require RCU-synchronisation before-hand because it does that internally. However, it does require rtnl-locking so insert that where necessary. Also clean up the code doing it internally to be a bit clearer and not synchronize twice if keys are configured. Signed-off-by: Johannes Berg <johannes@sipsolutions.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'net/mac80211/cfg.c')
-rw-r--r--net/mac80211/cfg.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/net/mac80211/cfg.c b/net/mac80211/cfg.c
index fbd462c78e18..5f8db5cab65d 100644
--- a/net/mac80211/cfg.c
+++ b/net/mac80211/cfg.c
@@ -700,11 +700,7 @@ static int ieee80211_del_station(struct wiphy *wiphy, struct net_device *dev,
700 return -ENOENT; 700 return -ENOENT;
701 701
702 sta_info_unlink(&sta); 702 sta_info_unlink(&sta);
703 703 sta_info_destroy(sta);
704 if (sta) {
705 synchronize_rcu();
706 sta_info_destroy(sta);
707 }
708 } else 704 } else
709 sta_info_flush(local, sdata); 705 sta_info_flush(local, sdata);
710 706