mac80211: fix SMPS debugfs locking
authorJohannes Berg <johannes.berg@intel.com>
Tue, 19 Apr 2011 18:44:04 +0000 (20:44 +0200)
committerSteve Conklin <sconklin@canonical.com>
Thu, 2 Jun 2011 19:23:15 +0000 (14:23 -0500)
commitc753aa8984e1ebfb27c1bd6bf4202eb74a8c5106
treed708df1481d10c48edfadb7abdcbe17cf9aa1efa
parent6b169c545582846144ce48fa5018ca45e0bc357d
mac80211: fix SMPS debugfs locking

BugLink: http://bugs.launchpad.net/bugs/780546

commit 243e6df4ed919880d079d717641ad699c6530a03 upstream.

The locking with SMPS requests means that the
debugs file should lock the mgd mutex, not the
iflist mutex. Calls to __ieee80211_request_smps()
need to hold that mutex, so add an assertion.

This has always been wrong, but for some reason
never been noticed, probably because the locking
error only happens while unassociated.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Tim Gardner <tim.gardner@canonical.com>
net/mac80211/cfg.c
net/mac80211/debugfs_netdev.c