linux/net/wireless
Johannes Berg 6913b49a50 regulatory: fix reg_is_valid_request handling
There's a bug with the world regulatory domain, it
can be updated any time which is different from all
other regdomains that can only be updated once after
a request for them. Fix this by adding a check for
"processed" to the reg_is_valid_request() function
and clear that when doing a request.

While looking at this I also found another locking
bug, last_request is protected by the reg_mutex not
the cfg80211_mutex so the code in nl80211 is racy.
Remove that code as it only tries to prevent an
allocation in an error case, which isn't necessary.
Then the function can also become static and locking
in nl80211 can have a smaller scope.

Also change __set_regdom() to do the checks earlier
and not different for world/other regdomains.

Acked-by: Luis R. Rodriguez <mcgrof@do-not-panic.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-01-03 13:01:28 +01:00
..
.gitignore wireless: support internal statically compiled regulatory database 2009-12-21 18:56:10 -05:00
ap.c cfg80211: store the ssid into wirless_dev in AP mode 2012-11-07 17:57:14 +01:00
chan.c cfg80211: check no-OFDM flag for channels wider than 20 MHz 2012-12-04 20:51:27 +01:00
core.c cfg80211: remove wiphy_idx_valid 2013-01-03 13:01:23 +01:00
core.h cfg80211: remove wiphy_idx_valid 2013-01-03 13:01:23 +01:00
db.txt wireless: support internal statically compiled regulatory database 2009-12-21 18:56:10 -05:00
debugfs.c simple_open: automatically convert to simple_open() 2012-04-05 15:25:50 -07:00
debugfs.h cfg80211/mac80211: use debugfs_remove_recursive 2009-10-30 16:49:18 -04:00
ethtool.c cfg80211: add wrappers for registered_device_ops 2012-10-18 10:53:37 +02:00
ethtool.h net/wireless/ethtool.h: drop unnecessary include of linux/ethtool.h 2009-10-07 16:39:49 -04:00
genregdb.awk cfg80211: relicense reg.c reg.h and genregdb.awk to ISC 2012-01-04 14:30:41 -05:00
ibss.c nl80211/cfg80211: support VHT channel configuration 2012-11-26 12:42:59 +01:00
Kconfig lib80211: hide Kconfig symbol 2012-11-16 14:29:09 -05:00
lib80211_crypt_ccmp.c net: Convert net_ratelimit uses to net_<level>_ratelimited 2012-05-15 13:45:03 -04:00
lib80211_crypt_tkip.c net: Convert net_ratelimit uses to net_<level>_ratelimited 2012-05-15 13:45:03 -04:00
lib80211_crypt_wep.c wireless: Remove unnecessary OOM logging messages 2011-09-13 15:45:02 -04:00
lib80211.c lib80211: remove exports for functions not called by other modules 2011-08-09 15:42:36 -04:00
Makefile cfg80211: add tracing to rdev-ops 2012-10-18 10:53:37 +02:00
mesh.c cfg80211: fix channel error on mesh join 2012-12-03 11:24:49 +01:00
mlme.c cfg80211: pass a channel definition struct 2012-11-26 12:42:58 +01:00
nl80211.c regulatory: fix reg_is_valid_request handling 2013-01-03 13:01:28 +01:00
nl80211.h cfg80211: pass a channel definition struct 2012-11-26 12:42:58 +01:00
radiotap.c wireless: add radiotap A-MPDU status field 2012-08-20 13:53:09 +02:00
rdev-ops.h cfg80211: pass a channel definition struct 2012-11-26 12:42:58 +01:00
reg.c regulatory: fix reg_is_valid_request handling 2013-01-03 13:01:28 +01:00
reg.h regulatory: fix reg_is_valid_request handling 2013-01-03 13:01:28 +01:00
regdb.h cfg80211: relicense reg.c reg.h and genregdb.awk to ISC 2012-01-04 14:30:41 -05:00
scan.c cfg80211: fix BSS struct IE access races 2012-11-30 13:42:20 +01:00
sme.c regulatory: code cleanup 2013-01-03 13:01:22 +01:00
sysfs.c cfg80211: add wrappers for registered_device_ops 2012-10-18 10:53:37 +02:00
sysfs.h
trace.c cfg80211: add tracing to rdev-ops 2012-10-18 10:53:37 +02:00
trace.h cfg80211: fix some tracing output issues 2012-11-26 12:48:17 +01:00
util.c cfg80211: fix BSS struct IE access races 2012-11-30 13:42:20 +01:00
wext-compat.c wext: explicitly cast -110 to u8 2012-12-07 11:58:26 +01:00
wext-compat.h cfg80211: remove unused wext handler exports 2011-08-08 14:26:29 -04:00
wext-core.c wext: include wireless event id when it has a size problem 2012-09-05 16:12:44 +02:00
wext-priv.c wext: fix potential private ioctl memory content leak 2010-09-20 13:41:40 -04:00
wext-proc.c net: spread __net_init, __net_exit 2010-01-17 19:16:02 -08:00
wext-sme.c cfg80211: fix BSS struct IE access races 2012-11-30 13:42:20 +01:00
wext-spy.c wireless: Convert compare_ether_addr to ether_addr_equal 2012-05-09 20:49:19 -04:00