Bug 548103 - iwlagn wireless driver using wrong regulatory domain
iwlagn wireless driver using wrong regulatory domain
Status: CLOSED ERRATA
Product: Fedora
Classification: Fedora
Component: crda (Show other bugs)
12
All Linux
low Severity medium
: ---
: ---
Assigned To: John W. Linville
Fedora Extras Quality Assurance
: Desktop
Depends On:
Blocks: 529341 548845
  Show dependency treegraph
 
Reported: 2009-12-16 11:05 EST by Suzanne Hillman
Modified: 2009-12-21 23:56 EST (History)
7 users (show)

See Also:
Fixed In Version: 1.1.0_2009.11.25-2.fc12
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
: 548845 (view as bug list)
Environment:
Last Closed: 2009-12-21 23:56:43 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
dmesg outpyt (68.50 KB, text/plain)
2009-12-16 14:38 EST, Cameron Meadors
no flags Details
shillman dmesg output (52.74 KB, text/plain)
2009-12-16 14:49 EST, Suzanne Hillman
no flags Details
contents of /etc/sysconfig/clock (199 bytes, text/plain)
2009-12-16 16:18 EST, Suzanne Hillman
no flags Details

  None (edit)
Description Suzanne Hillman 2009-12-16 11:05:23 EST
Description of problem:
iwlagn wireless driver using wrong regulatory domain. We are located in the US and using US hardware, but dmesg says:

cfg80211: Calling CRDA to update world regulatory domain
...
cfg80211: World regulatory domain updated:
	(start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp)
	(2402000 KHz - 2472000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
	(2457000 KHz - 2482000 KHz @ 20000 KHz), (300 mBi, 2000 mBm)
	(2474000 KHz - 2494000 KHz @ 20000 KHz), (300 mBi, 2000 mBm)
	(5170000 KHz - 5250000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
	(5735000 KHz - 5835000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)

lspci -nn says:

03:00.0 Network controller [0280]: Intel Corporation PRO/Wireless 5100 AGN [Shiloh] Network Connection [8086:4237]

Version-Release number of selected component (if applicable):
kernel-PAE-2.6.31.6-166.fc12.i686

How reproducible:
Always

Steps to Reproduce:
1. Load the driver
2. Look at dmesg
  
Actual results:
Uses World regulatory domain.

Expected results:
Use US regulatory domain!

Additional info:
Comment 1 John W. Linville 2009-12-16 13:34:48 EST
Did you set your system time using system-config-date?
Comment 2 Suzanne Hillman 2009-12-16 13:50:03 EST
I did not myself do so, no. I just did an install (with F11, then updated to f12).
Comment 3 Cameron Meadors 2009-12-16 13:57:01 EST
I also see in dmesg that the driver is using the world domain.  I have not specifically used system-config-date to change the time.  This is a fresh install of F12.
Comment 4 John W. Linville 2009-12-16 14:06:55 EST
Please post your complete dmesg output -- everything starts with the world domain, most things get updated by udev and/or the driver later.

Also, run "setregdomain" and post the difference in dmesg output.
Comment 5 Cameron Meadors 2009-12-16 14:38:09 EST
Forgot that `dmesg` has more information than /var/log/dmesg.  Attaching `dmesg` output.  Looks like cfg80211 does finally set domain to US.
Comment 6 Cameron Meadors 2009-12-16 14:38:37 EST
Created attachment 378825 [details]
dmesg outpyt
Comment 7 Suzanne Hillman 2009-12-16 14:48:13 EST
Ok. Attaching dmesg output. The difference between the two after I ran setregdomain was:

[root@firefly ~]# diff dmesg.output dmesg.output.afterset 
1095a1096,1104
> cfg80211: Calling CRDA for country: US
> cfg80211: Regulatory domain changed to country: US
> 	(start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp)
> 	(2402000 KHz - 2472000 KHz @ 40000 KHz), (300 mBi, 2700 mBm)
> 	(5170000 KHz - 5250000 KHz @ 40000 KHz), (300 mBi, 1700 mBm)
> 	(5250000 KHz - 5330000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
> 	(5490000 KHz - 5600000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
> 	(5650000 KHz - 5710000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
> 	(5735000 KHz - 5835000 KHz @ 40000 KHz), (300 mBi, 3000 mBm)
Comment 8 Suzanne Hillman 2009-12-16 14:49:10 EST
Created attachment 378827 [details]
shillman dmesg output
Comment 9 John W. Linville 2009-12-16 15:43:53 EST
Suzanne, please attach the contents of /etc/sysconfig/regdomain and
/etc/sysconfig/clock (or note it if one or both do not exist).
Comment 10 Suzanne Hillman 2009-12-16 16:18:13 EST
Created attachment 378852 [details]
contents of /etc/sysconfig/clock

FWIW, /etc/sysconfig/regdomain does not exist.
Comment 11 John W. Linville 2009-12-16 16:48:39 EST
Well, I'm not sure what is happening.  It looks like /etc/sysconfig/clock has what is needed and running setregdomain manually seems to work for you.  Does 'modprobe -r iwlagn ; modprobe iwlagn' produce fresh CRDA-related output in dmesg for you?
Comment 12 Suzanne Hillman 2009-12-17 14:40:58 EST
Diffing dmesg and dmesg after the modprobe gives:

< wlan0: deauthenticating by local choice (reason=3)
< iwlagn 0000:03:00.0: PCI INT A disabled
< cfg80211: Calling CRDA to update world regulatory domain
< cfg80211: World regulatory domain updated:
< 	(start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp)
< 	(2402000 KHz - 2472000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
< 	(2457000 KHz - 2482000 KHz @ 20000 KHz), (300 mBi, 2000 mBm)
< 	(2474000 KHz - 2494000 KHz @ 20000 KHz), (300 mBi, 2000 mBm)
< 	(5170000 KHz - 5250000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
< 	(5735000 KHz - 5835000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
< iwlagn: Intel(R) Wireless WiFi Link AGN driver for Linux, 1.3.27kds
< iwlagn: Copyright(c) 2003-2009 Intel Corporation
< iwlagn 0000:03:00.0: PCI INT A -> GSI 17 (level, low) -> IRQ 17
< iwlagn 0000:03:00.0: setting latency timer to 64
< iwlagn 0000:03:00.0: Detected Intel Wireless WiFi Link 5100AGN REV=0x54
< iwlagn 0000:03:00.0: Tunable channels: 13 802.11bg, 24 802.11a channels
< iwlagn 0000:03:00.0: irq 29 for MSI/MSI-X
< phy0: Selected rate control algorithm 'iwl-agn-rs'
< iwlagn 0000:03:00.0: firmware: requesting iwlwifi-5000-2.ucode
< iwlagn 0000:03:00.0: loaded firmware version 8.24.2.12
< Registered led device: iwl-phy0::radio
< Registered led device: iwl-phy0::assoc
< Registered led device: iwl-phy0::RX
< Registered led device: iwl-phy0::TX
< ADDRCONF(NETDEV_UP): wlan0: link is not ready
< wlan0: authenticate with AP 00:1d:7e:dc:3c:2c
< wlan0: authenticated
< wlan0: associate with AP 00:1d:7e:dc:3c:2c
< wlan0: RX AssocResp from 00:1d:7e:dc:3c:2c (capab=0x401 status=0 aid=1)
< wlan0: associated
< ADDRCONF(NETDEV_CHANGE): wlan0: link becomes ready
< wlan0: no IPv6 routers present
< tun0: Disabled Privacy Extensions
Comment 13 John W. Linville 2009-12-18 11:52:04 EST
Alright, just for completeness please confirm that
/lib/udev/rules.d/85-regulatory.rules looks like this:

# Runs CRDA for kernel wireless regulatory events.
# For more information see:
# http://wireless.kernel.org/en/developers/Regulatory/CRDA

SUBSYSTEM=="ieee80211", ACTION=="add", RUN+="/sbin/setregdomain"

KERNEL=="regulatory*", ACTION=="change", SUBSYSTEM=="platform", RUN+="/sbin//crda"

It looks like the first of those rules isn't getting run for some reason...
Comment 14 John W. Linville 2009-12-18 13:36:42 EST
OK, looks like it _is_ getting run, but setregdomain is silently failing due to not being able to find iw in its path.  I suspect this may have been broken for a while (i.e. since I moved iw from /usr/bin to /sbin).

Unfortunately, it looks like Fedora CVS is still not cooperating.  I'll get to this shortly after it becomes usable again.  In the meantime, you can either deal with the constrained set of wireless settings, call setregdomain manually, or hack /sbin/setregdomain to change "iw" to "/sbin/iw".

Thanks!
Comment 15 Suzanne Hillman 2009-12-18 14:05:19 EST
That file is as you put it above, although I suspect you knew this already.

And since this was being tested as part of trying to write testing for firmware in 5.5, I'll just keep working on that test plan and those cases in the meantime. :)
Comment 16 John W. Linville 2009-12-18 14:38:09 EST
Hey, I'm glad to have the bug report.  But FWIW, the udev stuff isn't in rhel5.5. :-)  The only method there for the _user_ (i.e. not the driver and not the AP) to specify a regdomain is to use the ieee80211_regdom option to the cfg80211 module -- FYI!
Comment 17 Fedora Update System 2009-12-18 14:53:02 EST
crda-1.1.0_2009.11.25-2.fc12 has been submitted as an update for Fedora 12.
http://admin.fedoraproject.org/updates/crda-1.1.0_2009.11.25-2.fc12
Comment 19 Fedora Update System 2009-12-21 23:56:38 EST
crda-1.1.0_2009.11.25-2.fc12 has been pushed to the Fedora 12 stable repository.  If problems still persist, please make note of it in this bug report.

Note You need to log in before you can comment on or make changes to this bug.