mac80211: fix SMPS debugfs locking
commit6ee931e9812bdf3774cbd74571d2fdfba037aac9
authorJohannes Berg <johannes.berg@intel.com>
Tue, 19 Apr 2011 18:44:04 +0000 (19 20:44 +0200)
committerGreg Kroah-Hartman <gregkh@suse.de>
Mon, 9 May 2011 22:06:46 +0000 (9 15:06 -0700)
tree28cd753e364fe0566e503870800b3ffcc6c6c75a
parentbf4b1d070aeb3669d4b4e95c59c404d0e055c41c
mac80211: fix SMPS debugfs locking

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>
net/mac80211/cfg.c
net/mac80211/debugfs_netdev.c