wifi: ath: split 5150-5350 regulatory rule
PATCH 1/1 wifi: ath: split 5150-5350 regulatory rule
Allow initiation in the 5150-5240 MHz portion of the world regulatory rule while retaining NO_IR for 5260-5350 MHz, where radar detection is required.
The previous single rule marked both ranges NO_IR and unnecessarily restricted channels 36-48. Update the rule counts for the expanded rule list.
--- drivers/net/wireless/ath/regd.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-)
drivers/net/wireless/ath/regd.c +7 -6
@@ -43,7 +43,8 @@ static int __ath_regd_init(struct ath_regulatory *reg); NL80211_RRF_NO_OFDM)/* We allow IBSS on these on a case by case basis by regulatory domain */ -#define ATH_5GHZ_5150_5350 REG_RULE(5150-10, 5350+10, 80, 0, 30,\ +#define ATH_5GHZ_5150_5350 REG_RULE(5150-10, 5240+10, 80, 0, 30, 0),\ + REG_RULE(5260-10, 5350+10, 80, 0, 30,\ NL80211_RRF_NO_IR)#define ATH_5GHZ_5470_5850 REG_RULE(5470-10, 5850+10, 80, 0, 30,\ NL80211_RRF_NO_IR)
@@ -64,7 +65,7 @@ static int __ath_regd_init(struct ath_regulatory *reg);/* Can be used for: * 0x60, 0x61, 0x62 */ static const struct ieee80211_regdomain ath_world_regdom_60_61_62 = { - .n_reg_rules =5 , + .n_reg_rules =6 , .alpha2 ="99" , .reg_rules = {ATH_2GHZ_ALL ,
@@ -74,7 +75,7 @@ static const struct ieee80211_regdomain ath_world_regdom_60_61_62 = {/* Can be used by 0x63 and 0x65 */ static const struct ieee80211_regdomain ath_world_regdom_63_65 = { - .n_reg_rules =4 , + .n_reg_rules =5 , .alpha2 ="99" , .reg_rules = {ATH_2GHZ_CH01_11 ,
@@ -85,7 +86,7 @@ static const struct ieee80211_regdomain ath_world_regdom_63_65 = {/* Can be used by 0x64 only */ static const struct ieee80211_regdomain ath_world_regdom_64 = { - .n_reg_rules =3 , + .n_reg_rules =4 , .alpha2 ="99" , .reg_rules = {ATH_2GHZ_CH01_11 ,
@@ -95,7 +96,7 @@ static const struct ieee80211_regdomain ath_world_regdom_64 = {/* Can be used by 0x66 and 0x69 */ static const struct ieee80211_regdomain ath_world_regdom_66_69 = { - .n_reg_rules =3 , + .n_reg_rules =4 , .alpha2 ="99" , .reg_rules = {ATH_2GHZ_CH01_11 ,
@@ -105,7 +106,7 @@ static const struct ieee80211_regdomain ath_world_regdom_66_69 = {/* Can be used by 0x67, 0x68, 0x6A and 0x6C */ static const struct ieee80211_regdomain ath_world_regdom_67_68_6A_6C = { - .n_reg_rules =4 , + .n_reg_rules =5 , .alpha2 ="99" , .reg_rules = {ATH_2GHZ_CH01_11 ,
Signature · 1 line
2.55.0
Quoted 7 lines · Rosen Penev
Allow initiation in the 5150-5240 MHz portion of the world regulatory rule while retaining
NO_IRfor 5260-5350 MHz, where radar detection is required.The previous single rule marked both ranges
NO_IRand unnecessarily restricted channels 36-48. Update the rule counts for the expanded rule list.
My understanding is that this is not correct. In world mode the entire 5 GHz band is restricted since some countries do not allow any transmission in that band. You must establish that you are in a supported regulatory domain via 802.11d or other mechanisms before transmission.
So I'm dropping this patch from patchwork
Quoted 66 lines
Assisted-by Codex:gpt-5.6-lunaSigned-off-by Rosen Penev <[email protected]>--- drivers/net/wireless/ath/regd.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-)drivers/net/wireless/ath/regd.c +7
-6@@ -43,7 +43,8 @@ static int __ath_regd_init(struct ath_regulatory *reg); NL80211_RRF_NO_OFDM)/* We allow IBSS on these on a case by case basis by regulatory domain */ -#define ATH_5GHZ_5150_5350 REG_RULE(5150-10, 5350+10, 80, 0, 30,\ +#define ATH_5GHZ_5150_5350 REG_RULE(5150-10, 5240+10, 80, 0, 30, 0),\ + REG_RULE(5260-10, 5350+10, 80, 0, 30,\ NL80211_RRF_NO_IR)#define ATH_5GHZ_5470_5850 REG_RULE(5470-10, 5850+10, 80, 0, 30,\ NL80211_RRF_NO_IR)@@ -64,7 +65,7 @@ static int __ath_regd_init(struct ath_regulatory *reg);/* Can be used for: * 0x60, 0x61, 0x62 */ static const struct ieee80211_regdomain ath_world_regdom_60_61_62 = { - .n_reg_rules =5 , + .n_reg_rules =6 , .alpha2 ="99" , .reg_rules = {ATH_2GHZ_ALL ,@@ -74,7 +75,7 @@ static const struct ieee80211_regdomain ath_world_regdom_60_61_62 = {/* Can be used by 0x63 and 0x65 */ static const struct ieee80211_regdomain ath_world_regdom_63_65 = { - .n_reg_rules =4 , + .n_reg_rules =5 , .alpha2 ="99" , .reg_rules = {ATH_2GHZ_CH01_11 ,@@ -85,7 +86,7 @@ static const struct ieee80211_regdomain ath_world_regdom_63_65 = {/* Can be used by 0x64 only */ static const struct ieee80211_regdomain ath_world_regdom_64 = { - .n_reg_rules =3 , + .n_reg_rules =4 , .alpha2 ="99" , .reg_rules = {ATH_2GHZ_CH01_11 ,@@ -95,7 +96,7 @@ static const struct ieee80211_regdomain ath_world_regdom_64 = {/* Can be used by 0x66 and 0x69 */ static const struct ieee80211_regdomain ath_world_regdom_66_69 = { - .n_reg_rules =3 , + .n_reg_rules =4 , .alpha2 ="99" , .reg_rules = {ATH_2GHZ_CH01_11 ,@@ -105,7 +106,7 @@ static const struct ieee80211_regdomain ath_world_regdom_66_69 = {/* Can be used by 0x67, 0x68, 0x6A and 0x6C */ static const struct ieee80211_regdomain ath_world_regdom_67_68_6A_6C = { - .n_reg_rules =4 , + .n_reg_rules =5 , .alpha2 ="99" , .reg_rules = {ATH_2GHZ_CH01_11 ,