]> git.baikalelectronics.ru Git - kernel.git/commit
mac80211: protect AP VLAN list with local->mtx
authorMichal Kazior <michal.kazior@tieto.com>
Wed, 5 Mar 2014 12:14:08 +0000 (13:14 +0100)
committerJohannes Berg <johannes.berg@intel.com>
Wed, 9 Apr 2014 08:55:49 +0000 (10:55 +0200)
commit0e85a2fd9e7acbfe547fe1ff4f372d3316dd973f
tree2fe457b25b558543257bb3c73d888e4f4bab8b5b
parent497479f57b751de3de97b3b18c5eb6a50a07ae0a
mac80211: protect AP VLAN list with local->mtx

It was impossible to change chanctx of master AP
for AP VLANs because the copy function requires
RTNL which can't be simply taken in mac80211 code
due to possible deadlocks.

This is required for future chanctx reservation
that re-bind vifs to new chanctx. This requires
safe AP VLAN iteration without RTNL.

Now VLANs can be iterated while holding either
RTNL or local->mtx because the list is modified
while holding both of these locks.

Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Luciano Coelho <luciano.coelho@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
net/mac80211/cfg.c
net/mac80211/chan.c
net/mac80211/ieee80211_i.h
net/mac80211/iface.c