mac80211: update to wireless-testing 2013-11-05
[openwrt/svn-archive/archive.git] / package / kernel / mac80211 / patches / 403-ath_regd_optional.patch
1 --- a/drivers/net/wireless/ath/regd.c
2 +++ b/drivers/net/wireless/ath/regd.c
3 @@ -196,6 +196,10 @@ ath_reg_apply_beaconing_flags(struct wip
4 struct ieee80211_channel *ch;
5 unsigned int i;
6
7 +#ifdef CPTCFG_ATH_USER_REGD
8 + return;
9 +#endif
10 +
11 for (band = 0; band < IEEE80211_NUM_BANDS; band++) {
12
13 if (!wiphy->bands[band])
14 @@ -249,6 +253,10 @@ ath_reg_apply_active_scan_flags(struct w
15 struct ieee80211_channel *ch;
16 const struct ieee80211_reg_rule *reg_rule;
17
18 +#ifdef CPTCFG_ATH_USER_REGD
19 + return;
20 +#endif
21 +
22 sband = wiphy->bands[IEEE80211_BAND_2GHZ];
23 if (!sband)
24 return;
25 @@ -298,6 +306,10 @@ static void ath_reg_apply_radar_flags(st
26 struct ieee80211_channel *ch;
27 unsigned int i;
28
29 +#ifdef CPTCFG_ATH_USER_REGD
30 + return;
31 +#endif
32 +
33 if (!wiphy->bands[IEEE80211_BAND_5GHZ])
34 return;
35
36 @@ -606,6 +618,10 @@ ath_regd_init_wiphy(struct ath_regulator
37 {
38 const struct ieee80211_regdomain *regd;
39
40 +#ifdef CPTCFG_ATH_USER_REGD
41 + return 0;
42 +#endif
43 +
44 wiphy->reg_notifier = reg_notifier;
45 wiphy->flags |= WIPHY_FLAG_STRICT_REGULATORY;
46
47 --- a/drivers/net/wireless/ath/Kconfig
48 +++ b/drivers/net/wireless/ath/Kconfig
49 @@ -21,6 +21,9 @@ menuconfig ATH_CARDS
50
51 if ATH_CARDS
52
53 +config ATH_USER_REGD
54 + bool "Do not enforce EEPROM regulatory restrictions"
55 +
56 config ATH_DEBUG
57 bool "Atheros wireless debugging"
58 ---help---
59 --- a/.local-symbols
60 +++ b/.local-symbols
61 @@ -126,6 +126,7 @@ RTL8187_LEDS=
62 ATH_COMMON=
63 ATH_CARDS=
64 ATH_DEBUG=
65 +ATH_USER_REGD=
66 ATH_REG_DYNAMIC_USER_REG_HINTS=
67 ATH_REG_DYNAMIC_USER_CERT_TESTING=
68 ATH5K=