[PATCH] mac80211: fix virtual interface locking
Florian Lohoff noticed a bug in mac80211: when bringing the master interface down while other virtual interfaces are up we call dev_close() under a spinlock which is not allowed. This patch removes the sub_if_lock used by mac80211 in favour of using an RCU list. All list manipulations are already done under rtnl so are well protected against each other, and the read-side locks we took in the RX and TX code are already in RCU read-side critical sections. Signed-off-by:Johannes Berg <johannes@sipsolutions.net> Cc: Florian Lohoff <flo@rfc822.org> Cc: Herbert Xu <herbert@gondor.apana.org.au> Cc: Michal Piotrowski <michal.k.k.piotrowski@gmail.com> Cc: Satyam Sharma <satyam@infradead.org> Signed-off-by:
Michael Wu <flamingice@sourmilk.net> Signed-off-by:
John W. Linville <linville@tuxdriver.com>
Showing
- net/mac80211/ieee80211.c 25 additions, 31 deletionsnet/mac80211/ieee80211.c
- net/mac80211/ieee80211_i.h 2 additions, 3 deletionsnet/mac80211/ieee80211_i.h
- net/mac80211/ieee80211_iface.c 14 additions, 17 deletionsnet/mac80211/ieee80211_iface.c
- net/mac80211/ieee80211_sta.c 6 additions, 6 deletionsnet/mac80211/ieee80211_sta.c
- net/mac80211/rx.c 4 additions, 5 deletionsnet/mac80211/rx.c
- net/mac80211/tx.c 7 additions, 3 deletionsnet/mac80211/tx.c
Loading
Please register or sign in to comment