zd1211rw: ignore unknown regulatory domain.
PATCH 1/1 zd1211rw: ignore unknown regulatory domain.
Hi,
I'm using PLANEX GW-US54GXS (2019:5303) and it works with the attached patch. Could you consider to merge the attached patch?
Problem: GW-US54GXS uses zd1211rw but zd1211rw doesn't have a regulatory domain reported by GW-US54GXS (0x49).
Solutions:
(1) add a new regulatory domain (0x49). Here is a patch to use the approach:
----
drivers/net/wireless/zd1211rw/zd_mac.c +1 -0
@@ -43,6 +43,7 @@ static struct zd_reg_alpha2_map reg_alpha2_map[] = { { ZD_REGDOMAIN_ETSI, "DE" }, /* Generic ETSI, use most restrictive */ { ZD_REGDOMAIN_JAPAN, "JP" }, { ZD_REGDOMAIN_JAPAN_ADD, "JP" }, + { ZD_REGDOMAIN_JAPAN_GW_US54GXS, "JP" }, { ZD_REGDOMAIN_SPAIN, "ES" }, { ZD_REGDOMAIN_FRANCE, "FR" }, };
drivers/net/wireless/zd1211rw/zd_mac.h +1 -0
@@ -214,6 +214,7 @@ struct zd_mac {#define ZD_REGDOMAIN_FRANCE 0x32#define ZD_REGDOMAIN_JAPAN_ADD 0x40#define ZD_REGDOMAIN_JAPAN 0x41 +#define ZD_REGDOMAIN_JAPAN_GW_US54GXS 0x49enum {MIN_CHANNEL24 =1 ,
----
(2) just ignore unknown regulatory domain. (the attached patch approach)
It seems that (2) is a better solution because we can change regulatory domain by CRDA (*).
(*) http://wireless.kernel.org/en/developers/Regulatory/CRDA
Thanks,
--
kou
Quoted 1 line
From
c230320db45e9261814b69e7596d4f641c3c8aadMon Sep 17 00:00:00 2001
From: Kouhei Sutou <[email protected]>
Date: Sun, 13 Jun 2010 14:37:54 +0900
Subject: [PATCH] zd1211rw: ignore unknown regulatory domain.
Zd1211rw supports 7 regulatory domains (ZD_REGDOMAIN_*) but they aren't cover all regulatory domains. For example, PLANEX GW-US54GXS (2019:5303) uses 0x49 for its regulatory domain.
If zd1211rw can't convert a regulatory domain to alpha2, it reports that initialization is failed. But we can change regulatory domain by another way (CRDA). So it seems that zd1211rw can ignore unknown regulatory domain.
--- drivers/net/wireless/zd1211rw/zd_mac.c | 6 ++---- 1 files changed, 2 insertions(+), 4 deletions(-)
drivers/net/wireless/zd1211rw/zd_mac.c +2 -4
@@ -198,11 +198,9 @@ int zd_mac_init_hw(struct ieee80211_hw *hw)if (r) goto disable_int; - r =zd_reg2alpha2 (mac->regdomain, alpha2); -if (r) - goto disable_int; +if (zd_reg2alpha2 (mac->regdomain, alpha2)) + r =regulatory_hint (hw->wiphy, alpha2); - r =regulatory_hint (hw->wiphy, alpha2); disable_int:zd_chip_disable_int (chip); out:
Signature · 1 line
1.7.1
Note: this e-mail is on a public mailing list!
Quoted 6 lines · Kouhei Sutou
Hi,
I'm using PLANEX GW-US54GXS (2019:5303) and it works with the attached patch. Could you consider to merge the attached patch?
Quoted 7 lines
Problem: GW-US54GXS uses zd1211rw but zd1211rw doesn't have a regulatory domain reported by GW-US54GXS (
0x49).Solutions:
(1) add a new regulatory domain (
0x49). Here is a patch to use the approach:
Stephen, David, does 0x49 map to JP for zd1211 ? Are there other ones? Here is our list so far:
#define ZD_REGDOMAIN_FCC 0x10 #define ZD_REGDOMAIN_IC 0x20 #define ZD_REGDOMAIN_ETSI 0x30 #define ZD_REGDOMAIN_SPAIN 0x31 #define ZD_REGDOMAIN_FRANCE 0x32 #define ZD_REGDOMAIN_JAPAN_ADD 0x40 #define ZD_REGDOMAIN_JAPAN 0x41
This is what they map to:
static struct zd_reg_alpha2_map reg_alpha2_map[] = {
{ ZD_REGDOMAIN_FCC, "US" },
{ ZD_REGDOMAIN_IC, "CA" },
{ ZD_REGDOMAIN_ETSI, "DE" }, /* Generic ETSI, use most restrictive */
{ ZD_REGDOMAIN_JAPAN, "JP" },
{ ZD_REGDOMAIN_JAPAN_ADD, "JP" },
{ ZD_REGDOMAIN_SPAIN, "ES" },
{ ZD_REGDOMAIN_FRANCE, "FR" },
};Kouhei, if no regulatory domain is found, instead we should world roam, we cannot allow letting the user change regulatory domains at their whim. We can, however let them choose one to help compliance, but you can only help compliance once you know your actual regulatory domain.
Luis
Hi,
In <[email protected]>
"Re: [PATCH] zd1211rw: ignore unknown regulatory domain." on Sun, 13 Jun 2010 13:23:20 -0700,
Quoted 14 lines · Luis R. Rodriguez
Quoted 11 lines
I'm using PLANEX GW-US54GXS (2019:5303) and it works with the attached patch. Could you consider to merge the attached patch?
Problem: GW-US54GXS uses zd1211rw but zd1211rw doesn't have a regulatory domain reported by GW-US54GXS (
0x49).Solutions:
(1) add a new regulatory domain (
0x49). Here is a patch to use the approach:Stephen, David, does
0x49map to JP for zd1211 ? Are there other ones? Here is our list so far:
...
Quoted 5 lines
Kouhei, if no regulatory domain is found, instead we should world roam, we cannot allow letting the user change regulatory domains at their whim. We can, however let them choose one to help compliance, but you can only help compliance once you know your actual regulatory domain.
Luis, thanks for your input.
It seems that we can't use GW-US54GXS until 0x49 regulatory domain is registered to zd1211rw. Is it right?
If it is right, what I can do for GW-US54GXS? Should I wait a response from Stephen and/or David?
Thanks,
--
kou
Quoted 27 lines · Kouhei Sutou
Hi,
In <[email protected]>
"Re: [PATCH] zd1211rw: ignore unknown regulatory domain." on Sun, 13 Jun 2010 13:23:20 -0700,Quoted 14 lines · Luis R. Rodriguez
Quoted 11 lines
I'm using PLANEX GW-US54GXS (2019:5303) and it works with the attached patch. Could you consider to merge the attached patch?
Problem: GW-US54GXS uses zd1211rw but zd1211rw doesn't have a regulatory domain reported by GW-US54GXS (
0x49).Solutions:
(1) add a new regulatory domain (
0x49). Here is a patch to use the approach:Stephen, David, does
0x49map to JP for zd1211 ? Are there other ones? Here is our list so far:...
Quoted 5 lines
Kouhei, if no regulatory domain is found, instead we should world roam, we cannot allow letting the user change regulatory domains at their whim. We can, however let them choose one to help compliance, but you can only help compliance once you know your actual regulatory domain.
Quoted 6 lines
Luis, thanks for your input.
It seems that we can't use GW-US54GXS until0x49regulatory domain is registered to zd1211rw. Is it right?If it is right, what I can do for GW-US54GXS? Should I wait a response from Stephen and/or David?
We spoke and 0x49 - > JP is ok, can you send a patch for that?
Luis
Quoted 28 lines · Luis R. Rodriguez
Note: this e-mail is on a public mailing list!
Quoted 6 lines · Kouhei Sutou
Hi,
I'm using PLANEX GW-US54GXS (2019:5303) and it works with the attached patch. Could you consider to merge the attached patch?
Quoted 7 lines
Problem: GW-US54GXS uses zd1211rw but zd1211rw doesn't have a regulatory domain reported by GW-US54GXS (
0x49).Solutions:
(1) add a new regulatory domain (
0x49). Here is a patch to use the approach:Stephen, David, does
0x49map to JP for zd1211 ? Are there other ones? Here is our list so far:#define
ZD_REGDOMAIN_FCC0x10
#defineZD_REGDOMAIN_IC0x20
#defineZD_REGDOMAIN_ETSI0x30
#defineZD_REGDOMAIN_SPAIN0x31
#defineZD_REGDOMAIN_FRANCE0x32
#defineZD_REGDOMAIN_JAPAN_ADD0x40
#defineZD_REGDOMAIN_JAPAN0x41
Quoted 6 lines
This is what they map to:
static struct
zd_reg_alpha2_mapreg_alpha2_map[] = {
{ZD_REGDOMAIN_FCC, "US" },
{ZD_REGDOMAIN_IC, "CA" },
{ZD_REGDOMAIN_ETSI, "DE" }, /* Generic ETSI, use most restrictive */
Note: This one is causing me problems here in Hungary, as it keeps resetting my regdomain to Germany. I believe we should implement allowing the user to choose regdomain in this case, but allowing only regdomains in ETSI.
Quoted 18 lines
{
ZD_REGDOMAIN_JAPAN, "JP" },
{ZD_REGDOMAIN_JAPAN_ADD, "JP" },
{ZD_REGDOMAIN_SPAIN, "ES" },
{ZD_REGDOMAIN_FRANCE, "FR" },
};Kouhei, if no regulatory domain is found, instead we should world roam, we cannot allow letting the user change regulatory domains at their whim. We can, however let them choose one to help compliance, but you can only help compliance once you know your actual regulatory domain.
Luis
--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Signature · 1 line
Vista: [V]iruses, [I]ntruders, [S]pyware, [T]rojans and [A]dware. :-)
Hi,
In <[email protected]>
"Re: [PATCH] zd1211rw: ignore unknown regulatory domain." on Tue, 15 Jun 2010 08:22:09 -0700,
Quoted 28 lines · Luis R. Rodriguez
Quoted 27 lines · Kouhei Sutou
Hi,
In <[email protected]>
"Re: [PATCH] zd1211rw: ignore unknown regulatory domain." on Sun, 13 Jun 2010 13:23:20 -0700,Quoted 14 lines · Luis R. Rodriguez
Quoted 11 lines
I'm using PLANEX GW-US54GXS (2019:5303) and it works with the attached patch. Could you consider to merge the attached patch?
Problem: GW-US54GXS uses zd1211rw but zd1211rw doesn't have a regulatory domain reported by GW-US54GXS (
0x49).Solutions:
(1) add a new regulatory domain (
0x49). Here is a patch to use the approach:Stephen, David, does
0x49map to JP for zd1211 ? Are there other ones? Here is our list so far:...
Quoted 5 lines
Kouhei, if no regulatory domain is found, instead we should world roam, we cannot allow letting the user change regulatory domains at their whim. We can, however let them choose one to help compliance, but you can only help compliance once you know your actual regulatory domain.
Quoted 8 lines
Quoted 6 lines
Luis, thanks for your input.
It seems that we can't use GW-US54GXS until0x49regulatory domain is registered to zd1211rw. Is it right?If it is right, what I can do for GW-US54GXS? Should I wait a response from Stephen and/or David?
We spoke and
0x49- > JP is ok, can you send a patch for that?
OK.
I'll attach a patch for that.
I used 'ZD_REGDOMAIN_JAPAN_GW_US54GXS' as a macro name for 0x49 because 0x49 is used by GW-US54GXS. Is it OK? Or should I use other name for it?
Thanks,
--
kou
Quoted 1 line
From
a530e66e6e995d8e8bc00ece2a9b3540ef88688fMon Sep 17 00:00:00 2001
From: Kouhei Sutou <[email protected]>
Date: Wed, 16 Jun 2010 21:53:59 +0900
Subject: [PATCH] zd1211rw: add 0x49 -> JP regulatory domain map
0x49 is used by PLANEX GW-US54GXS (2019:5303).
--- drivers/net/wireless/zd1211rw/zd_mac.c | 1 + drivers/net/wireless/zd1211rw/zd_mac.h | 1 + 2 files changed, 2 insertions(+), 0 deletions(-)
drivers/net/wireless/zd1211rw/zd_mac.c +1 -0
@@ -43,6 +43,7 @@ static struct zd_reg_alpha2_map reg_alpha2_map[] = { { ZD_REGDOMAIN_ETSI, "DE" }, /* Generic ETSI, use most restrictive */ { ZD_REGDOMAIN_JAPAN, "JP" }, { ZD_REGDOMAIN_JAPAN_ADD, "JP" }, + { ZD_REGDOMAIN_JAPAN_GW_US54GXS, "JP" }, { ZD_REGDOMAIN_SPAIN, "ES" }, { ZD_REGDOMAIN_FRANCE, "FR" }, };
drivers/net/wireless/zd1211rw/zd_mac.h +1 -0
@@ -214,6 +214,7 @@ struct zd_mac {#define ZD_REGDOMAIN_FRANCE 0x32#define ZD_REGDOMAIN_JAPAN_ADD 0x40#define ZD_REGDOMAIN_JAPAN 0x41 +#define ZD_REGDOMAIN_JAPAN_GW_US54GXS 0x49enum {MIN_CHANNEL24 =1 ,
Signature · 1 line
1.7.1
Quoted 3 lines · Kouhei Sutou
I used '
ZD_REGDOMAIN_JAPAN_GW_US54GXS' as a macro name for0x49because0x49is used by GW-US54GXS. Is it OK? Or should I use other name for it?
Hopefully someone can suggest a better name. Anyone know what inspired "ZD_REGDOMAIN_JAPAN_ADD"?
John
Signature · 2 lines
John W. Linville Someday the world will need a hero, and you [email protected] might be all we have. Be ready.
Hi,
In <[email protected]>
"Re: [PATCH] zd1211rw: ignore unknown regulatory domain." on Wed, 16 Jun 2010 09:44:22 -0400,
Quoted 8 lines · John W. Linville
Quoted 3 lines · Kouhei Sutou
I used '
ZD_REGDOMAIN_JAPAN_GW_US54GXS' as a macro name for0x49because0x49is used by GW-US54GXS. Is it OK? Or should I use other name for it?Hopefully someone can suggest a better name. Anyone know what inspired "
ZD_REGDOMAIN_JAPAN_ADD"?
'ZD_REGDOMAIN_JAPAN_3' was used in another patch:
https://patchwork.kernel.org/patch/47220/
But I don't know why '3' was used...
Thanks,
--
kou
Quoted 12 lines · Kouhei Sutou
Hi,
In <[email protected]>
"Re: [PATCH] zd1211rw: ignore unknown regulatory domain." on Wed, 16 Jun 2010 09:44:22 -0400,Quoted 6 lines · John W. Linville
Quoted 3 lines · Kouhei Sutou
I used '
ZD_REGDOMAIN_JAPAN_GW_US54GXS' as a macro name for0x49because0x49is used by GW-US54GXS. Is it OK? Or should I use other name for it?
Quoted 7 lines
Quoted 2 lines
Hopefully someone can suggest a better name. Anyone know what inspired "
ZD_REGDOMAIN_JAPAN_ADD"?'
ZD_REGDOMAIN_JAPAN_3' was used in another patch:
https://patchwork.kernel.org/patch/47220/But I don't know why '3' was used...
'3' makes sense to me. The better question is why not change 'ADD' to '2'? :-)
John
Signature · 2 lines
John W. Linville Someday the world will need a hero, and you [email protected] might be all we have. Be ready.
Quoted 16 lines · John W. Linville
Quoted 15 lines · Kouhei Sutou
Hi,
In <[email protected]>
"Re: [PATCH] zd1211rw: ignore unknown regulatory domain." on Wed, 16 Jun 2010 09:44:22 -0400,Quoted 8 lines · John W. Linville
Quoted 3 lines · Kouhei Sutou
I used '
ZD_REGDOMAIN_JAPAN_GW_US54GXS' as a macro name for0x49because0x49is used by GW-US54GXS. Is it OK? Or should I use other name for it?Hopefully someone can suggest a better name. Anyone know what inspired "
ZD_REGDOMAIN_JAPAN_ADD"?
Quoted 6 lines
Quoted 4 lines
'
ZD_REGDOMAIN_JAPAN_3' was used in another patch:
https://patchwork.kernel.org/patch/47220/But I don't know why '3' was used...
'3' makes sense to me. The better question is why not change 'ADD' to '2'? :-)
2 is fine to replace ADD, I think "ADD" is additional :P
Luis