Modify

Opened 7 years ago

Closed 3 years ago

#8228 closed defect (worksforme)

Country Setting ignored in trunk on WNDR3700

Reported by: Stephan Owned by: developers
Priority: normal Milestone: Chaos Calmer 15.05
Component: packages Version: Trunk
Keywords: country code Cc:

Description

Hi,

I've noticed that I can no longer set the Country code
in recent trunk on WNDR3700. I live in Germany and cannot
use all channels because of that (which doesn't reallyy hurt me
too much since I use channel 1 anyway).
In ealier Versions of backfire branch I've seen messages in DMESG
saying: callind crda for country "DE", but now, it is only
called for "US". Also
COUNTRY=DE crda
on CLI doesn't work. Results in "Failed to set regulatory domain: -7"

Thanks a lot,
best regards,
Stephan

Attachments (0)

Change History (16)

comment:1 Changed 7 years ago by hauke

  • Resolution set to worksforme
  • Status changed from new to closed

I am unable to reproduce this in recent trunk.

The config is case sensitive and the key must be in lower case and the country code name must be in capital letters.

When setting
uci set wireless.radio0.country=DE

I get:

cfg80211: Calling CRDA for country: DE
cfg80211: Regulatory domain changed to country: DE
    (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp)
    (2400000 KHz - 2483500 KHz @ 40000 KHz), (N/A, 2000 mBm)
    (5150000 KHz - 5350000 KHz @ 40000 KHz), (N/A, 2000 mBm)
    (5470000 KHz - 5725000 KHz @ 40000 KHz), (N/A, 2698 mBm)

comment:2 Changed 7 years ago by docterd

  • Resolution worksforme deleted
  • Status changed from closed to reopened

Got the same problem here. Compiled today (23986) with regdomain but I can't change the country too.

comment:3 Changed 7 years ago by Stephan

just checked out and compiled r23917 and have the same error.

uci set wireless.radio0.country=DE


gives me nothing, as if cfg80211 isn't triggered.

Can that be cause though a missing option when compiling ?

regards,
Stzephan

comment:4 Changed 7 years ago by Stephan

Found out that in

/sys/module/cfg80211/parameters/ieee80211_regdom

the regdomain is set to 00. Maybe that's just a default
from the cfg80211 Module, or it is so because it is read from EEPROM,
I don't know.
I also found a workaround. Editing

/etc/modules.d/20-cfg80211

to give the correct regdomain to the module works for me:

cfg80211 ieee80211_regdom=DE

That allows me to use the German channels. I still cannot change the regdomain afterwards,
but I can live with it for now very well.

I've set the ATH_USER_REG config option, but maybe that one just does no longer work?

Regards,

Stephan

comment:5 Changed 7 years ago by anonymous

That didn't work out for me

cat /sys/module/cfg80211/parameters/ieee80211_regdom
DE
dmesg | grep CRDA
cfg80211: Calling CRDA to update world regulatory domain
cfg80211: Calling CRDA for country: DE
cfg80211: Calling CRDA for country: US
cfg80211: Calling CRDA for country: US

comment:6 Changed 7 years ago by anonymous

It works with trunk (24136) now. No module options, just the country setting in UCI.

root@OpenWrt:~# dmesg | grep CRDA
cfg80211: Calling CRDA to update world regulatory domain
cfg80211: Calling CRDA for country: US
cfg80211: Calling CRDA for country: NO

comment:7 Changed 7 years ago by jow

  • Resolution set to wontfix
  • Status changed from reopened to closed

We're not allowed to release builds with regdomain overrides.

comment:8 Changed 7 years ago by anonymous

  • Resolution wontfix deleted
  • Status changed from closed to reopened

It's OK that you are not allowed to override regdomain rules. But why European users can't change regrowain to their country? Why is it set to US?

comment:9 Changed 7 years ago by anonymous

Most Atheros devices have World regdomain in EEPROM. Vendors do not bother changing settings for different counties, allowing select a country in software.
Current Openwrt driver reads EEPROM regdomain and sets it accordingly.
This is wrong because it is to restricting.

comment:10 Changed 7 years ago by jow

  • Resolution set to wontfix
  • Status changed from reopened to closed

This does not change the fact that OpenWrt will not allow users to change the regdomain in binary releases.

comment:11 Changed 7 years ago by Dmitry Tunin <hanipouspilot@…>

  • Resolution wontfix deleted
  • Status changed from closed to reopened

I suggest the followng. Leave the same policy of restricting regdomain according to EEPROM. But for devices where regdomain is not set, allow user to set it.
For example. I have a 100% legal Tp-Link bought in Russia with Russian firmware.
But see the Openwrt log

ath: EEPROM regdomain: 0x0
ath: EEPROM indicates default country code should be used
ath: doing EEPROM country->regdmn map search
ath: country maps to regdmn code: 0x3a
ath: Country alpha2 being used: US
ath: Regpair used: 0x3a

It means that regdomain is not set (0x0) and Openwrt tries to set some country which randoms to USA as lowest in CRDA db. That is wrong.
Actually it violates restrictions. Russian restrictions are similar to most Eeuropean countries. 13 channels, but only 20dBm.
US is 11 channels with 27dBm. So it allows to set too high tx power.

What do you think of changing ath9k behavior with devices with 0x0 in EEPROM?
This with allow to set proper regdomain for their country for devices not locked by vendor.

comment:12 Changed 4 years ago by jow

  • Milestone changed from Backfire 10.03.2 to Chaos Calmer (trunk)

Milestone Backfire 10.03.2 deleted

comment:13 Changed 3 years ago by anonymous

Hello,

I have the same problem. I would like to comply with airwaves regulation from france and cannot because setting is US by EEPROM default. (I live in France)

It should be allowed to set the country because otherwise I cannot use the right, regulated channels for my country.

I don't understand the problem of changing country if it stays within the boundaries of what the manufacturer has set in silicon (channel presets).

Look at the following :

Not allowing user will put them in awkward situation (cannot comply with local regulations if set in EEPROM)

Allowing will enable user to comply with regulations or not comply (they choose).

I'd like to be able to choose to comply, and cannot.

Otherwise openWrt is a bless.

Cheers

comment:14 Changed 3 years ago by anonymous

It is not illegal to release a firmware which allows changing of the country settings. It is impossible to FCC certify a device, which allows modification of country settings.

OpenWRT is firmware that is used globally, whether the regulatory domain is put into the firmware from the computer or whether the regulatory domain is changable from the CLI makes very little difference if you're allowed to change the firmware anyway.

For European, Japanese users, the world setting is too restrictive and there it is legal to have the ability to change the regulatory domain.

Only two countries disallow this: United States and Israel. But that hardly covers custom firmwares where it can be changed in the code anyway.

comment:15 Changed 3 years ago by anonymous

I solved that problem long ago. You can always build Openwrt from source with the option to change regdomain.

comment:16 Changed 3 years ago by nbd

  • Resolution set to worksforme
  • Status changed from reopened to closed

Add Comment

Modify Ticket

Action
as closed .
The resolution will be deleted. Next status will be 'reopened'.
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.