Re: [ath5k-devel] Atheros HW/cfg80211 ignore nonUS regdom with "EEPROM regdomain: 0x0"

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Jiri Moravec
Date: Monday, March 22, 2010 - 9:56 am

On 22.3.2010 13:06, Lukáš Turek wrote:
After I modified EEPROM regdom on both cards to 0x36, 'iw reg get' give me correct regdom name in original configuration, but I spotted strange thing:

When I swaped wifi cards (AR5413 > PCI0, AR5001X+ -> PCI1) I get this:

------------------------------------------------------------------------
~ # iw phy
Wiphy phy1   <-------- AR5001X+
	Band 1:
		Frequencies:
			...
			* 2462 MHz [11] (20.0 dBm)
			* 2467 MHz [12] (20.0 dBm)
			* 2472 MHz [13] (20.0 dBm)
			* 2484 MHz [14] (disabled)
			...
Wiphy phy0   <-------- AR5413
	Band 1:
		Frequencies:
			...
			* 2462 MHz [11] (20.0 dBm)
			* 2467 MHz [12] (disabled)  <--------------------
			* 2472 MHz [13] (disabled)  <--------------------
			* 2484 MHz [14] (disabled)
			...
~ # iw reg get
country CZ:
	(2400 - 2483 @ 40), (N/A, 20)
	(5150 - 5250 @ 40), (N/A, 23), NO-OUTDOOR
	(5250 - 5350 @ 40), (N/A, 23), NO-OUTDOOR, DFS
	(5470 - 5725 @ 40), (N/A, 30), DFS

~ # dmesg
cfg80211: Calling CRDA to update world regulatory domain
cfg80211: Calling CRDA for country: CZ
ath5k 0000:03:05.0: PCI INT A -> GSI 20 (level, low) -> IRQ 20
ath5k 0000:03:05.0: registered as 'phy0'
cfg80211: Regulatory domain changed to country: CZ
    (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp)
    (2400000 KHz - 2483500 KHz @ 40000 KHz), (N/A, 2000 mBm)
    (5150000 KHz - 5250000 KHz @ 40000 KHz), (N/A, 2301 mBm)
    (5250000 KHz - 5350000 KHz @ 40000 KHz), (N/A, 2301 mBm)
    (5470000 KHz - 5725000 KHz @ 40000 KHz), (N/A, 3000 mBm)
ath: EEPROM regdomain: 0x36
ath: EEPROM indicates we should expect a direct regpair map
ath: Country alpha2 being used: CZ
ath: Regpair used: 0x36
phy0: Selected rate control algorithm 'minstrel'
ath5k phy0: Atheros AR5414 chip found (MAC: 0xa5, PHY: 0x61)
ath5k 0000:03:06.0: PCI INT A -> GSI 21 (level, low) -> IRQ 21
ath5k 0000:03:06.0: registered as 'phy1'
cfg80211: Calling CRDA for country: CZ
ath: EEPROM regdomain: 0x36
ath: EEPROM indicates we should expect a direct regpair map
ath: Country alpha2 being used: CZ
ath: Regpair used: 0x36
phy1: Selected rate control algorithm 'minstrel'
ath5k phy1: Atheros AR5212 chip found (MAC: 0x56, PHY: 0x41)
ath5k phy1: RF5111 5GHz radio found (0x17)
ath5k phy1: RF2111 2GHz radio found (0x23)
------------------------------------------------------------------------

When I swapped them back (AR5001X+ -> PCI0, AR5413 > PCI1) I get this:
------------------------------------------------------------------------
~ # iw phy
Wiphy phy1   <-------- AR5413
	Band 1:
		Frequencies:
			...
			* 2462 MHz [11] (20.0 dBm)
			* 2467 MHz [12] (20.0 dBm)  <--------------------
			* 2472 MHz [13] (20.0 dBm)  <--------------------
			* 2484 MHz [14] (disabled)
			...
Wiphy phy0   <-------- AR5001X+
	Band 1:
		Frequencies:
			...
			* 2462 MHz [11] (20.0 dBm)
			* 2467 MHz [12] (20.0 dBm)
			* 2472 MHz [13] (20.0 dBm)
			* 2484 MHz [14] (disabled)
			...

~ # iw reg get
country 98:   <-------- !
	(2402 - 2472 @ 40), (N/A, 20)
	(2457 - 2482 @ 20), (N/A, 20), PASSIVE-SCAN, NO-IBSS
	(2474 - 2483 @ 9), (N/A, 20), NO-OFDM, PASSIVE-SCAN, NO-IBSS
	(5170 - 5250 @ 40), (N/A, 20), NO-OUTDOOR, PASSIVE-SCAN, NO-IBSS

~ # dmesg
cfg80211: Calling CRDA to update world regulatory domain
cfg80211: Calling CRDA for country: CZ
ath5k 0000:03:05.0: PCI INT A -> GSI 20 (level, low) -> IRQ 20
ath5k 0000:03:05.0: registered as 'phy0'
ath: EEPROM regdomain: 0x36
ath: EEPROM indicates we should expect a direct regpair map
ath: Country alpha2 being used: CZ
ath: Regpair used: 0x36
phy0: Selected rate control algorithm 'minstrel'
ath5k phy0: Atheros AR5212 chip found (MAC: 0x56, PHY: 0x41)
ath5k phy0: RF5111 5GHz radio found (0x17)
ath5k phy0: RF2111 2GHz radio found (0x23)
ath5k 0000:03:06.0: PCI INT A -> GSI 21 (level, low) -> IRQ 21
ath5k 0000:03:06.0: registered as 'phy1'
cfg80211: Calling CRDA for country: CZ
udev: renamed network interface wlan0 to wlan1
cfg80211: Current regulatory domain intersected: 
    (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp)
    (2402000 KHz - 2472000 KHz @ 40000 KHz), (N/A, 2000 mBm)
    (2457000 KHz - 2482000 KHz @ 20000 KHz), (N/A, 2000 mBm)
    (2474000 KHz - 2483500 KHz @ 9500 KHz), (N/A, 2000 mBm)
    (5170000 KHz - 5250000 KHz @ 40000 KHz), (N/A, 2000 mBm)
cfg80211: Current regulatory domain intersected: 
    (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp)
    (2402000 KHz - 2472000 KHz @ 40000 KHz), (N/A, 2000 mBm)
    (2457000 KHz - 2482000 KHz @ 20000 KHz), (N/A, 2000 mBm)
    (2474000 KHz - 2483500 KHz @ 9500 KHz), (N/A, 2000 mBm)
    (5170000 KHz - 5250000 KHz @ 40000 KHz), (N/A, 2000 mBm)
ath: EEPROM regdomain: 0x36
ath: EEPROM indicates we should expect a direct regpair map
ath: Country alpha2 being used: CZ
ath: Regpair used: 0x36
phy1: Selected rate control algorithm 'minstrel'
cfg80211: Calling CRDA for country: CZ
ath5k phy1: Atheros AR5414 chip found (MAC: 0xa5, PHY: 0x61)
cfg80211: Current regulatory domain intersected: 
    (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp)
    (2402000 KHz - 2472000 KHz @ 40000 KHz), (N/A, 2000 mBm)
    (2457000 KHz - 2482000 KHz @ 20000 KHz), (N/A, 2000 mBm)
    (2474000 KHz - 2483500 KHz @ 9500 KHz), (N/A, 2000 mBm)
    (5170000 KHz - 5250000 KHz @ 40000 KHz), (N/A, 2000 mBm)
------------------------------------------------------------------------


In first case I can change regdom (only in kernel, actually hw ignore it)
------------------------------------------------------------------------
~ # iw reg get
country CZ:          
        (2400 - 2483 @ 40), (N/A, 20)
        (5150 - 5250 @ 40), (N/A, 23), NO-OUTDOOR
        (5250 - 5350 @ 40), (N/A, 23), NO-OUTDOOR, DFS
        (5470 - 5725 @ 40), (N/A, 30), DFS            

~ # iw reg set JP

~ # iw reg get
country JP:          
        (2402 - 2472 @ 40), (N/A, 20)
        (2457 - 2482 @ 20), (N/A, 20)
        (2474 - 2494 @ 20), (N/A, 20), NO-OFDM
        (4910 - 4930 @ 10), (N/A, 23)         
        (4910 - 4990 @ 40), (N/A, 23)         
        (4930 - 4950 @ 10), (N/A, 23)         
        (5030 - 5045 @ 10), (N/A, 23)         
        (5030 - 5090 @ 40), (N/A, 23)         
        (5050 - 5060 @ 10), (N/A, 23)         
        (5170 - 5250 @ 40), (N/A, 20)         
        (5250 - 5330 @ 40), (N/A, 20), DFS    
        (5490 - 5710 @ 40), (N/A, 23), DFS    

~ # iw phy
Wiphy phy1       
        Band 1:  
                Frequencies:
                        * 2412 MHz [1] (20.0 dBm)
                        * 2417 MHz [2] (20.0 dBm)
                        * 2422 MHz [3] (20.0 dBm)
                        * 2427 MHz [4] (20.0 dBm)
                        * 2432 MHz [5] (20.0 dBm)
                        * 2437 MHz [6] (20.0 dBm)
                        * 2442 MHz [7] (20.0 dBm)
                        * 2447 MHz [8] (20.0 dBm)
                        * 2452 MHz [9] (20.0 dBm)
                        * 2457 MHz [10] (20.0 dBm)
                        * 2462 MHz [11] (20.0 dBm)
                        * 2467 MHz [12] (20.0 dBm)
                        * 2472 MHz [13] (20.0 dBm)
                        * 2484 MHz [14] (disabled) <----------- !
------------------------------------------------------------------------


In second case this is ignored:
------------------------------------------------------------------------
~ # iw reg set JP

~ # iw reg get
country 98:
	(2402 - 2472 @ 40), (N/A, 20)
	(2457 - 2482 @ 20), (N/A, 20), PASSIVE-SCAN, NO-IBSS
	(2474 - 2483 @ 9), (N/A, 20), NO-OFDM, PASSIVE-SCAN, NO-IBSS
	(5170 - 5250 @ 40), (N/A, 20), NO-OUTDOOR, PASSIVE-SCAN, NO-IBSS
------------------------------------------------------------------------

Is it a bug, feature or there are sunspots?
In ALL cases changing regdom by 'iw reg set' ISN'T working. Driver/HW actually ignore changing regdomain.

Can somebody explain me this behavior?

Thanks
Jiri Moravec

_______________________________________________
ath5k-devel mailing list
ath5k-devel@lists.ath5k.org
https://lists.ath5k.org/mailman/listinfo/ath5k-devel
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
Re: [ath5k-devel] Atheros HW/cfg80211 ignore nonUS regdom ..., Jiri Moravec, (Mon Mar 22, 9:56 am)