From b16bd15c379410f2aa47837aa4a0de5712856ad5 Mon Sep 17 00:00:00 2001 From: Johannes Berg Date: Fri, 11 Apr 2008 21:40:35 +0200 Subject: mac80211: fix spinlock recursion When STAs are expired, we need to hold the sta_lock. Using the same lock for keys too would then mean we'd need another key free function, and that'll just lead to confusion, so just use a new spinlock for all key lists. Signed-off-by: Johannes Berg Signed-off-by: John W. Linville --- net/mac80211/main.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'net/mac80211/main.c') diff --git a/net/mac80211/main.c b/net/mac80211/main.c index bfcbcf5353a..e9a978979d3 100644 --- a/net/mac80211/main.c +++ b/net/mac80211/main.c @@ -1587,6 +1587,8 @@ struct ieee80211_hw *ieee80211_alloc_hw(size_t priv_data_len, INIT_LIST_HEAD(&local->interfaces); + spin_lock_init(&local->key_lock); + INIT_DELAYED_WORK(&local->scan_work, ieee80211_sta_scan_work); sta_info_init(local); -- cgit v1.2.3