summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLuis R. Rodriguez <lrodriguez@atheros.com>2009-01-22 15:05:50 -0800
committerJohn W. Linville <linville@tuxdriver.com>2009-01-29 16:01:17 -0500
commitd46e5b1d0c617a2a46353812d7f02115c17b5e72 (patch)
tree7774dd44cad9a9b9a73f4830c119271af17ee9b0
parent2a44f911d8bac3e6c97a25cc612e4324dfbdfdc4 (diff)
downloadop-kernel-dev-d46e5b1d0c617a2a46353812d7f02115c17b5e72.zip
op-kernel-dev-d46e5b1d0c617a2a46353812d7f02115c17b5e72.tar.gz
cfg80211: move check for ignore_reg_update() on wiphy_update_regulatory()
This ensures that the initial REGDOM_SET_BY_CORE upon wiphy registration respects the wiphy->custom_regulatory setting. Without this and if OLD_REG is disabled (which will be default soon as we remove it) the wiphy->custom_regulatory is simply ignored. Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com> Acked-by: Johannes Berg <johannes@sipsolutions.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
-rw-r--r--net/wireless/reg.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/net/wireless/reg.c b/net/wireless/reg.c
index 5db02a3..81acb07 100644
--- a/net/wireless/reg.c
+++ b/net/wireless/reg.c
@@ -937,13 +937,15 @@ static void update_all_wiphy_regulatory(enum reg_set_by setby)
struct cfg80211_registered_device *drv;
list_for_each_entry(drv, &cfg80211_drv_list, list)
- if (!ignore_reg_update(&drv->wiphy, setby))
- wiphy_update_regulatory(&drv->wiphy, setby);
+ wiphy_update_regulatory(&drv->wiphy, setby);
}
void wiphy_update_regulatory(struct wiphy *wiphy, enum reg_set_by setby)
{
enum ieee80211_band band;
+
+ if (ignore_reg_update(wiphy, setby))
+ return;
for (band = 0; band < IEEE80211_NUM_BANDS; band++) {
if (wiphy->bands[band])
handle_band(wiphy, band);
OpenPOWER on IntegriCloud