diff options
author | Johannes Berg <johannes@sipsolutions.net> | 2009-04-20 18:30:49 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-04-22 16:57:19 -0400 |
commit | 29b4a4f7c7b588b5568edd0da42f38623b81fc66 (patch) | |
tree | 4c607b2e053f7f5a4f4d1a10b46d949ba42b5f50 /net/mac80211/ibss.c | |
parent | 0cf4c01ebe2ccf4487fe9301bab905365dca06c3 (diff) |
mac80211: fix IBSS code to not sleep while atomic
With the RCU locking here we sleep while in an atomic context,
since we can sleep just use mutex locking for the interface
list instead of RCU. Sorry, seems I didn't get that in my UML
test.
Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'net/mac80211/ibss.c')
-rw-r--r-- | net/mac80211/ibss.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/net/mac80211/ibss.c b/net/mac80211/ibss.c index 4f7a54518be4..6030e003180c 100644 --- a/net/mac80211/ibss.c +++ b/net/mac80211/ibss.c | |||
@@ -784,14 +784,14 @@ void ieee80211_ibss_notify_scan_completed(struct ieee80211_local *local) | |||
784 | { | 784 | { |
785 | struct ieee80211_sub_if_data *sdata; | 785 | struct ieee80211_sub_if_data *sdata; |
786 | 786 | ||
787 | rcu_read_lock(); | 787 | mutex_lock(&local->iflist_mtx); |
788 | list_for_each_entry_rcu(sdata, &local->interfaces, list) { | 788 | list_for_each_entry(sdata, &local->interfaces, list) { |
789 | if (sdata->vif.type != NL80211_IFTYPE_ADHOC) | 789 | if (sdata->vif.type != NL80211_IFTYPE_ADHOC) |
790 | continue; | 790 | continue; |
791 | sdata->u.ibss.last_scan_completed = jiffies; | 791 | sdata->u.ibss.last_scan_completed = jiffies; |
792 | ieee80211_sta_find_ibss(sdata); | 792 | ieee80211_sta_find_ibss(sdata); |
793 | } | 793 | } |
794 | rcu_read_unlock(); | 794 | mutex_unlock(&local->iflist_mtx); |
795 | } | 795 | } |
796 | 796 | ||
797 | ieee80211_rx_result | 797 | ieee80211_rx_result |