invalid regdomain: 0x5c (was: problem with D-Link DWA-160)
A message that is not in the archive (sent off-list or not yet received): [email protected]
Quoted 9 lines · On Wednesday 06 April 2011 05:26:28 Joe Culler wrote:
[...]
I have a problem with carl9170 driver with my d-link dwa-160 under linux-2.6.39-rc1.
Here's the dmesg:[ 3114.257063] ath: EEPROM regdomain: 0x5c [ 3114.257066] ath: EEPROM indicates we should expect a direct regpair map [ 3114.257069] ath: invalid regulatory domain/country code 0x5c [ 3114.257071] ath: Invalid EEPROM contents
clearly, the regdomain code 0x5c is not defined in the drivers/net/wireless/ath/regd_common.h => regDomainPairs struct.
this would be easy to fix [see attached patch], however I'm not quite sure what to do about the 5GHz band in this case, since the CTL_FCC is more restrictive than it should be.
Regards,
Chr
---
drivers/net/wireless/ath/regd_common.h +1 -0
@@ -195,6 +195,7 @@ static struct reg_dmn_pair_mapping regDomainPairs[] = { {APL9_WORLD, CTL_ETSI, CTL_ETSI}, {APL3_FCCA, CTL_FCC, CTL_FCC}, + {APL7_FCCA, CTL_FCC, CTL_FCC}, {APL1_ETSIC, CTL_FCC, CTL_ETSI}, {APL2_ETSIC, CTL_FCC, CTL_ETSI}, {APL2_APLD, CTL_FCC, NO_CTL},
Luis R. Rodriguez
Acked-byQuoted 26 lines · Christian Lamparter
Quoted 9 lines · On Wednesday 06 April 2011 05:26:28 Joe Culler wrote:
[...]
I have a problem with carl9170 driver with my d-link dwa-160 under linux-2.6.39-rc1.
Here's the dmesg:[ 3114.257063] ath: EEPROM regdomain: 0x5c [ 3114.257066] ath: EEPROM indicates we should expect a direct regpair map [ 3114.257069] ath: invalid regulatory domain/country code 0x5c [ 3114.257071] ath: Invalid EEPROM contentsclearly, the regdomain code
0x5cis not defined in thedrivers/net/wireless/ath/regd_common.h=> regDomainPairs struct.this would be easy to fix [see attached patch], however I'm not quite sure what to do about the 5GHz band in this case, since the
CTL_FCCis more restrictive than it should be.Regards,
Chr---
drivers/net/wireless/ath/regd_common.h +0
-0
drivers/net/wireless/ath/regd_common.h static struct reg_dmn_pair_mapping regDomainPairs[] = { · line 201
Quoted 7 lines
drivers/net/wireless/ath/regd_common.h +1
-0@@ -195,6 +195,7 @@ static struct reg_dmn_pair_mapping regDomainPairs[] = { {APL9_WORLD, CTL_ETSI, CTL_ETSI}, {APL3_FCCA, CTL_FCC, CTL_FCC}, + {APL7_FCCA, CTL_FCC, CTL_FCC}, {APL1_ETSIC, CTL_FCC, CTL_ETSI}, {APL2_ETSIC, CTL_FCC, CTL_ETSI}, {APL2_APLD, CTL_FCC, NO_CTL},
I verified internally with our other code and this is correct, APL7 maps to FCC CTL and FCCA maps to FCC CTL as well. For an upstream patch:
Luis
Quoted 40 lines · Luis R. Rodriguez
Quoted 26 lines · Christian Lamparter
Quoted 9 lines · On Wednesday 06 April 2011 05:26:28 Joe Culler wrote:
[...]
I have a problem with carl9170 driver with my d-link dwa-160 under linux-2.6.39-rc1.
Here's the dmesg:[ 3114.257063] ath: EEPROM regdomain: 0x5c [ 3114.257066] ath: EEPROM indicates we should expect a direct regpair map [ 3114.257069] ath: invalid regulatory domain/country code 0x5c [ 3114.257071] ath: Invalid EEPROM contentsclearly, the regdomain code
0x5cis not defined in thedrivers/net/wireless/ath/regd_common.h=> regDomainPairs struct.this would be easy to fix [see attached patch], however I'm not quite sure what to do about the 5GHz band in this case, since the
CTL_FCCis more restrictive than it should be.Regards,
Chr---
drivers/net/wireless/ath/regd_common.h +0
-0drivers/net/wireless/ath/regd_common.h static struct reg_dmn_pair_mapping regDomainPairs[] = { · line 201
Quoted 7 lines
drivers/net/wireless/ath/regd_common.h +1
-0@@ -195,6 +195,7 @@ static struct reg_dmn_pair_mapping regDomainPairs[] = { {APL9_WORLD, CTL_ETSI, CTL_ETSI}, {APL3_FCCA, CTL_FCC, CTL_FCC}, + {APL7_FCCA, CTL_FCC, CTL_FCC}, {APL1_ETSIC, CTL_FCC, CTL_ETSI}, {APL2_ETSIC, CTL_FCC, CTL_ETSI}, {APL2_APLD, CTL_FCC, NO_CTL},I verified internally with our other code and this is correct, APL7 maps to FCC CTL and FCCA maps to FCC CTL as well. For an upstream patch:
Quoted 1 line
Oh and please Cc [email protected], thanks a lot!
Luis
Quoted 42 lines · Luis R. Rodriguez
Quoted 40 lines · Luis R. Rodriguez
Quoted 26 lines · Christian Lamparter
Quoted 9 lines · On Wednesday 06 April 2011 05:26:28 Joe Culler wrote:
[...]
I have a problem with carl9170 driver with my d-link dwa-160 under linux-2.6.39-rc1.
Here's the dmesg:[ 3114.257063] ath: EEPROM regdomain: 0x5c [ 3114.257066] ath: EEPROM indicates we should expect a direct regpair map [ 3114.257069] ath: invalid regulatory domain/country code 0x5c [ 3114.257071] ath: Invalid EEPROM contentsclearly, the regdomain code
0x5cis not defined in thedrivers/net/wireless/ath/regd_common.h=> regDomainPairs struct.this would be easy to fix [see attached patch], however I'm not quite sure what to do about the 5GHz band in this case, since the
CTL_FCCis more restrictive than it should be.Regards,
Chr---
drivers/net/wireless/ath/regd_common.h +0
-0drivers/net/wireless/ath/regd_common.h static struct reg_dmn_pair_mapping regDomainPairs[] = { · line 201
Quoted 7 lines
drivers/net/wireless/ath/regd_common.h +1
-0@@ -195,6 +195,7 @@ static struct reg_dmn_pair_mapping regDomainPairs[] = { {APL9_WORLD, CTL_ETSI, CTL_ETSI}, {APL3_FCCA, CTL_FCC, CTL_FCC}, + {APL7_FCCA, CTL_FCC, CTL_FCC}, {APL1_ETSIC, CTL_FCC, CTL_ETSI}, {APL2_ETSIC, CTL_FCC, CTL_ETSI}, {APL2_APLD, CTL_FCC, NO_CTL},I verified internally with our other code and this is correct, APL7 maps to FCC CTL and FCCA maps to FCC CTL as well. For an upstream patch:
Quoted 3 lines
Quoted 1 line
Oh and please Cc [email protected], thanks a lot!
...and don't forget the Signed-off-by...
Signature · 2 lines
John W. Linville Someday the world will need a hero, and you [email protected] might be all we have. Be ready.
PATCH 1/1 ath: add missing regdomain pair 0x5c mapping
In reply to Luis R. RodriguezJoe Culler reported a problem with his AR9170 device:
Quoted 4 lines
ath: EEPROM regdomain:
0x5c
ath: EEPROM indicates we should expect a direct regpair map
ath: invalid regulatory domain/country code0x5c
ath: Invalid EEPROM contents
It turned out that the regdomain 'APL7_FCCA' was not mapped yet. According to Luis R. Rodriguez [Atheros' engineer] APL7 maps to FCC_CTL and FCCA maps to FCC_CTL as well, so the attached patch should be correct.
---
Joe,
does this patch fix your problem? If so, can you please reply with a "tested-by:" tag?
Regards,
Christian
---
drivers/net/wireless/ath/regd_common.h +1 -0
@@ -195,6 +195,7 @@ static struct reg_dmn_pair_mapping regDomainPairs[] = { {APL9_WORLD, CTL_ETSI, CTL_ETSI}, {APL3_FCCA, CTL_FCC, CTL_FCC}, + {APL7_FCCA, CTL_FCC, CTL_FCC}, {APL1_ETSIC, CTL_FCC, CTL_ETSI}, {APL2_ETSIC, CTL_FCC, CTL_ETSI}, {APL2_APLD, CTL_FCC, NO_CTL},
Hello Christian,
Your patch works for me, thanks.
Tested-by: Joe Culler
Quoted 36 lines · Christian Lamparter
Quoted 9 lines · On Wednesday 06 April 2011 05:26:28 Joe Culler wrote:
[...]
I have a problem with carl9170 driver with my d-link dwa-160 under linux-2.6.39-rc1.
Here's the dmesg:[ 3114.257063] ath: EEPROM regdomain: 0x5c [ 3114.257066] ath: EEPROM indicates we should expect a direct regpair map [ 3114.257069] ath: invalid regulatory domain/country code 0x5c [ 3114.257071] ath: Invalid EEPROM contentsclearly, the regdomain code
0x5cis not defined in thedrivers/net/wireless/ath/regd_common.h=> regDomainPairs struct.this would be easy to fix [see attached patch], however I'm not quite sure what to do about the 5GHz band in this case, since the
CTL_FCCis more restrictive than it should be.Regards,
Chr---
drivers/net/wireless/ath/regd_common.h +1
-0@@ -195,6 +195,7 @@ static struct reg_dmn_pair_mapping regDomainPairs[] = { {APL9_WORLD, CTL_ETSI, CTL_ETSI}, {APL3_FCCA, CTL_FCC, CTL_FCC}, + {APL7_FCCA, CTL_FCC, CTL_FCC}, {APL1_ETSIC, CTL_FCC, CTL_ETSI}, {APL2_ETSIC, CTL_FCC, CTL_ETSI}, {APL2_APLD, CTL_FCC, NO_CTL},