aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/ath/regd.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/wireless/ath/regd.c')
-rw-r--r--drivers/net/wireless/ath/regd.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/drivers/net/wireless/ath/regd.c b/drivers/net/wireless/ath/regd.c
index 077bcc142cde..00489c40be0c 100644
--- a/drivers/net/wireless/ath/regd.c
+++ b/drivers/net/wireless/ath/regd.c
@@ -15,7 +15,6 @@
15 */ 15 */
16 16
17#include <linux/kernel.h> 17#include <linux/kernel.h>
18#include <linux/slab.h>
19#include <net/cfg80211.h> 18#include <net/cfg80211.h>
20#include <net/mac80211.h> 19#include <net/mac80211.h>
21#include "regd.h" 20#include "regd.h"
@@ -110,8 +109,9 @@ static const struct ieee80211_regdomain ath_world_regdom_67_68_6A = {
110 109
111static inline bool is_wwr_sku(u16 regd) 110static inline bool is_wwr_sku(u16 regd)
112{ 111{
113 return ((regd & WORLD_SKU_MASK) == WORLD_SKU_PREFIX) || 112 return ((regd & COUNTRY_ERD_FLAG) != COUNTRY_ERD_FLAG) &&
114 (regd == WORLD); 113 (((regd & WORLD_SKU_MASK) == WORLD_SKU_PREFIX) ||
114 (regd == WORLD));
115} 115}
116 116
117static u16 ath_regd_get_eepromRD(struct ath_regulatory *reg) 117static u16 ath_regd_get_eepromRD(struct ath_regulatory *reg)
@@ -450,7 +450,7 @@ ath_regd_init_wiphy(struct ath_regulatory *reg,
450 const struct ieee80211_regdomain *regd; 450 const struct ieee80211_regdomain *regd;
451 451
452 wiphy->reg_notifier = reg_notifier; 452 wiphy->reg_notifier = reg_notifier;
453 wiphy->strict_regulatory = true; 453 wiphy->flags |= WIPHY_FLAG_STRICT_REGULATORY;
454 454
455 if (ath_is_world_regd(reg)) { 455 if (ath_is_world_regd(reg)) {
456 /* 456 /*
@@ -458,8 +458,7 @@ ath_regd_init_wiphy(struct ath_regulatory *reg,
458 * saved on the wiphy orig_* parameters 458 * saved on the wiphy orig_* parameters
459 */ 459 */
460 regd = ath_world_regdomain(reg); 460 regd = ath_world_regdomain(reg);
461 wiphy->custom_regulatory = true; 461 wiphy->flags |= WIPHY_FLAG_CUSTOM_REGULATORY;
462 wiphy->strict_regulatory = false;
463 } else { 462 } else {
464 /* 463 /*
465 * This gets applied in the case of the absense of CRDA, 464 * This gets applied in the case of the absense of CRDA,