diff options
author | Johannes Berg <johannes.berg@intel.com> | 2013-12-30 17:12:37 -0500 |
---|---|---|
committer | Johannes Berg <johannes.berg@intel.com> | 2013-12-30 17:14:03 -0500 |
commit | 194ff52d42fd0b55fe0fcfbf4586ae9d7ab1f780 (patch) | |
tree | eddb4c40ce1cc7a8aa590b1aeaf162a8a8bdba5a /net/mac80211/cfg.c | |
parent | 32db6b54dfba38aa8fa4072b2a3fc6425139166a (diff) |
cfg80211/mac80211: correct qos-map locking
Since the RTNL can't always be held, use wdev/sdata locking for
the qos-map dereference in mac80211. This requires cfg80211 to
consistently lock it, which it was missing in one place.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'net/mac80211/cfg.c')
-rw-r--r-- | net/mac80211/cfg.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/mac80211/cfg.c b/net/mac80211/cfg.c index 09d2e58a2ba7..fd1020e791d8 100644 --- a/net/mac80211/cfg.c +++ b/net/mac80211/cfg.c | |||
@@ -3854,7 +3854,7 @@ static int ieee80211_set_qos_map(struct wiphy *wiphy, | |||
3854 | new_qos_map = NULL; | 3854 | new_qos_map = NULL; |
3855 | } | 3855 | } |
3856 | 3856 | ||
3857 | old_qos_map = rtnl_dereference(sdata->qos_map); | 3857 | old_qos_map = sdata_dereference(sdata->qos_map, sdata); |
3858 | rcu_assign_pointer(sdata->qos_map, new_qos_map); | 3858 | rcu_assign_pointer(sdata->qos_map, new_qos_map); |
3859 | if (old_qos_map) | 3859 | if (old_qos_map) |
3860 | kfree_rcu(old_qos_map, rcu_head); | 3860 | kfree_rcu(old_qos_map, rcu_head); |