2012-05-14 08:10:05

by Holger Schurig

[permalink] [raw]
Subject: [BUG, ath9k]: NUL bytes at end of /sys/kernel/debug/ieee80211/phy0/ath9k/modal_eeprom

At first I wondered why "grep -i ant ." in this phy0/ath9k directory
just said "Binary file modal_eeprom matches". But when I used "less
modal_eeprom", I saw a bunch of NUL bytes at the end of the virtual
file.

--
http://www.holgerschurig.de


2012-05-14 13:25:38

by Mohammed Shafi

[permalink] [raw]
Subject: Re: [BUG, ath9k]: NUL bytes at end of /sys/kernel/debug/ieee80211/phy0/ath9k/modal_eeprom

>
> root@/sys/kernel/debug/ieee80211/phy0/ath9k# xxd <modal_eeprom | tail -4
> 0000630: 2036 0a20 2020 2020 2020 2054 5820 4469 ? 6. ? ? ? ?TX Di
> 0000640: 7665 7273 6974 7920 3a20 2020 2020 2020 ?versity :
> 0000650: 2020 2030 0a00 0000 0000 0000 0000 0000 ? ? 0............
> 0000660: 0000 0000 0000 0000 0000 0000 ? ? ? ? ? ?............
>
> --


will soon send a RFC patch for your testing, i tested this it seems to
be working!


--
thanks,
shafi

2012-05-14 13:48:04

by Mohammed Shafi

[permalink] [raw]
Subject: Re: [BUG, ath9k]: NUL bytes at end of /sys/kernel/debug/ieee80211/phy0/ath9k/modal_eeprom

Hi Holger,

On Mon, May 14, 2012 at 6:55 PM, Mohammed Shafi
<[email protected]> wrote:
>>
>> root@/sys/kernel/debug/ieee80211/phy0/ath9k# xxd <modal_eeprom | tail -4
>> 0000630: 2036 0a20 2020 2020 2020 2054 5820 4469 ? 6. ? ? ? ?TX Di
>> 0000640: 7665 7273 6974 7920 3a20 2020 2020 2020 ?versity :
>> 0000650: 2020 2030 0a00 0000 0000 0000 0000 0000 ? ? 0............
>> 0000660: 0000 0000 0000 0000 0000 0000 ? ? ? ? ? ?............
>>

please try with the attached patch. seems to be working. i check if
its fine and review it internally. thank you!

--
thanks,
shafi


Attachments:
fix-eeprom-debug.patch (4.91 kB)

2012-05-14 12:02:44

by Mohammed Shafi

[permalink] [raw]
Subject: Re: [BUG, ath9k]: NUL bytes at end of /sys/kernel/debug/ieee80211/phy0/ath9k/modal_eeprom

On Mon, May 14, 2012 at 2:11 PM, Holger Schurig
<[email protected]> wrote:
> root@/sys/kernel/debug/ieee80211/phy0/ath9k# cat modal_eeprom
> ? 2GHz modal Header :
> ?Chain0 Ant. Control : ? ? ? ? ?0
> ?Ant. Common Control : ? ? ? ? ?0
> ? ?Chain0 Ant. Gain : ? ? ? ? ?0
> ? ? ? Switch Settle : ? ? ? ? 44
> ? ?Chain0 TxRxAtten : ? ? ? ? 32
> ? Chain0 RxTxMargin : ? ? ? ? ?0
> ? ?ADC Desired size : ? ? ? ?226
> ? ?PGA Desired size : ? ? ? ? ?0
> ? ?Chain0 xlna Gain : ? ? ? ? 13
> ? ? ? txEndToXpaOff : ? ? ? ? ?0
> ? ? ? ? txEndToRxOn : ? ? ? ? ?2
> ? ? ?txFrameToXpaOn : ? ? ? ? 14
> ? ? ?CCA Threshold) : ? ? ? ? 28
> ?Chain0 NF Threshold : ? ? ? ?186
> ? ? ? ? ? ? xpdGain : ? ? ? ? 10
> ? ? ? ? External PD : ? ? ? ? ?1
> Chain0 I Coefficient : ? ? ? ? ?0
> Chain0 Q Coefficient : ? ? ? ? ?0
> ? ? ? pdGainOverlap : ? ? ? ? ?6
> ? ?O/D Bias Version : ? ? ? ? ?3
> ? ? ?CCK OutputBias : ? ? ? ? ?6
> ? ? BPSK OutputBias : ? ? ? ? ?4
> ? ? QPSK OutputBias : ? ? ? ? ?4
> ? ?16QAM OutputBias : ? ? ? ? ?4
> ? ?64QAM OutputBias : ? ? ? ? ?4
> ? ?CCK Driver1_Bias : ? ? ? ? ?4
> ? BPSK Driver1_Bias : ? ? ? ? ?3
> ? QPSK Driver1_Bias : ? ? ? ? ?3
> ?16QAM Driver1_Bias : ? ? ? ? ?3
> ?64QAM Driver1_Bias : ? ? ? ? ?3
> ? ?CCK Driver2_Bias : ? ? ? ? ?4
> ? BPSK Driver2_Bias : ? ? ? ? ?3
> ? QPSK Driver2_Bias : ? ? ? ? ?3
> ?16QAM Driver2_Bias : ? ? ? ? ?3
> ?64QAM Driver2_Bias : ? ? ? ? ?3
> ? ? ?xPA Bias Level : ? ? ? ? ?1
> ?txFrameToDataStart : ? ? ? ? 14
> ? ? ? txFrameToPaOn : ? ? ? ? 14
> ? ? HT40 Power Inc. : ? ? ? ? ?0
> ? ? Chain0 bswAtten : ? ? ? ? ?0
> ? ?Chain0 bswMargin : ? ? ? ? 31
> ?HT40 Switch Settle : ? ? ? ? 44
> ? ?Chain0 xatten2Db : ? ? ? ? ?0
> Chain0 xatten2Margin : ? ? ? ? ?0
> ?Ant. Diversity ctl1 : ? ? ? ? 11
> ?Ant. Diversity ctl2 : ? ? ? ? ?6
> ? ? ? ?TX Diversity : ? ? ? ? ?0
>
> root@/sys/kernel/debug/ieee80211/phy0/ath9k# xxd <modal_eeprom | tail -4
> 0000630: 2036 0a20 2020 2020 2020 2054 5820 4469 ? 6. ? ? ? ?TX Di
> 0000640: 7665 7273 6974 7920 3a20 2020 2020 2020 ?versity :
> 0000650: 2020 2030 0a00 0000 0000 0000 0000 0000 ? ? 0............
> 0000660: 0000 0000 0000 0000 0000 0000 ? ? ? ? ? ?............
>
> --
> http://www.holgerschurig.de

oh yes, thanks we will look into it.


--
thanks,
shafi

2012-05-14 08:23:05

by Mohammed Shafi

[permalink] [raw]
Subject: Re: [BUG, ath9k]: NUL bytes at end of /sys/kernel/debug/ieee80211/phy0/ath9k/modal_eeprom

Hi,

On Mon, May 14, 2012 at 1:40 PM, Holger Schurig
<[email protected]> wrote:
> At first I wondered why "grep -i ant ." in this phy0/ath9k directory
> just said "Binary file modal_eeprom matches". But when I used "less
> modal_eeprom", I saw a bunch of NUL bytes at the end of the virtual
> file.

please dump the whole contents you had got

>
> --
> http://www.holgerschurig.de
> --
> 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



--
thanks,
shafi

2012-05-14 08:41:15

by Holger Schurig

[permalink] [raw]
Subject: Re: [BUG, ath9k]: NUL bytes at end of /sys/kernel/debug/ieee80211/phy0/ath9k/modal_eeprom

root@/sys/kernel/debug/ieee80211/phy0/ath9k# cat modal_eeprom
2GHz modal Header :
Chain0 Ant. Control : 0
Ant. Common Control : 0
Chain0 Ant. Gain : 0
Switch Settle : 44
Chain0 TxRxAtten : 32
Chain0 RxTxMargin : 0
ADC Desired size : 226
PGA Desired size : 0
Chain0 xlna Gain : 13
txEndToXpaOff : 0
txEndToRxOn : 2
txFrameToXpaOn : 14
CCA Threshold) : 28
Chain0 NF Threshold : 186
xpdGain : 10
External PD : 1
Chain0 I Coefficient : 0
Chain0 Q Coefficient : 0
pdGainOverlap : 6
O/D Bias Version : 3
CCK OutputBias : 6
BPSK OutputBias : 4
QPSK OutputBias : 4
16QAM OutputBias : 4
64QAM OutputBias : 4
CCK Driver1_Bias : 4
BPSK Driver1_Bias : 3
QPSK Driver1_Bias : 3
16QAM Driver1_Bias : 3
64QAM Driver1_Bias : 3
CCK Driver2_Bias : 4
BPSK Driver2_Bias : 3
QPSK Driver2_Bias : 3
16QAM Driver2_Bias : 3
64QAM Driver2_Bias : 3
xPA Bias Level : 1
txFrameToDataStart : 14
txFrameToPaOn : 14
HT40 Power Inc. : 0
Chain0 bswAtten : 0
Chain0 bswMargin : 31
HT40 Switch Settle : 44
Chain0 xatten2Db : 0
Chain0 xatten2Margin : 0
Ant. Diversity ctl1 : 11
Ant. Diversity ctl2 : 6
TX Diversity : 0

root@/sys/kernel/debug/ieee80211/phy0/ath9k# xxd <modal_eeprom | tail -4
0000630: 2036 0a20 2020 2020 2020 2054 5820 4469 6. TX Di
0000640: 7665 7273 6974 7920 3a20 2020 2020 2020 versity :
0000650: 2020 2030 0a00 0000 0000 0000 0000 0000 0............
0000660: 0000 0000 0000 0000 0000 0000 ............

--
http://www.holgerschurig.de