diff options
author | Luis R. Rodriguez <mcgrof@do-not-panic.com> | 2013-12-14 20:09:06 +0100 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2014-01-13 14:46:58 -0500 |
commit | 4f7b91404cd5da3657a82b00394f4f5dfbff13d6 (patch) | |
tree | d111dd2ecec10bddc417f77b3f75203fd064acb0 /net/wireless/reg.c | |
parent | 8fc685803a8d7b42a5f69dcad7f7cef6f8b60edf (diff) | |
download | talos-op-linux-4f7b91404cd5da3657a82b00394f4f5dfbff13d6.tar.gz talos-op-linux-4f7b91404cd5da3657a82b00394f4f5dfbff13d6.zip |
cfg80211: make regulatory_hint() remove REGULATORY_CUSTOM_REG
The REGULATORY_CUSTOM_REG can be used during early init with
the goal of overriding the wiphy's default regulatory settings
in case the alpha2 of the device is not known. In the case that
the alpha2 becomes known lets avoid having drivers having to
clear the REGULATORY_CUSTOM_REG flag by doing it for them
when regulatory_hint() is used.
Cc: Sujith Manoharan <c_manoha@qca.qualcomm.com>
Signed-off-by: Luis R. Rodriguez <mcgrof@do-not-panic.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'net/wireless/reg.c')
-rw-r--r-- | net/wireless/reg.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/net/wireless/reg.c b/net/wireless/reg.c index 7d20d844ca60..9b897fca7487 100644 --- a/net/wireless/reg.c +++ b/net/wireless/reg.c @@ -1853,6 +1853,8 @@ int regulatory_hint(struct wiphy *wiphy, const char *alpha2) if (WARN_ON(!alpha2 || !wiphy)) return -EINVAL; + wiphy->regulatory_flags &= ~REGULATORY_CUSTOM_REG; + request = kzalloc(sizeof(struct regulatory_request), GFP_KERNEL); if (!request) return -ENOMEM; |