I am more then happy to share the trace... Unfortunately compat-trace
does not compile on a 2.6.25 kernel properly (missing syms), so I am
using compat-wireless with my kernel patched with the mmio-trace patch.
This means that my traces, are missing the ath_hal function names. Let
me know where you would like me to put my trace files?

It is a 2425, most certainly. I am using compat-wireless, but I have
pulled in a chunk of updated code from a "test4" tar.gz i found
mentioned in this mailing list.

The trace I performed however was before I updated this code, so you
might be right, it is being set wrong by the old code (yes, its set
wrongly to 0x12, not 0xeb, I am dyslexic, so sue me :P). I will do
another trace and try again.

If you have an updated snapshot, please point me to it, I would love to
get stuck in and make the radio work in this thing. 

One thing I have noticed with ath_info is that on my chip, the latest
version from SVN identifies my device as having only g support, while
the madwifi driver reports b and g support. I have dug into the eeprom
code, and from what I can tell, it has not been updated to support the
2425 device.

Anyway, here is my dump:
 -==Device Information==-
MAC Version:  2425  (0xe0)
MAC Revision: 2425  (0xe2)
Warning: Invalid EEPROM Magic number!
Device type:  3

/============== EEPROM Information =============\
| EEPROM Version:   5.3 | EEPROM Size:   4 kbit |
| EEMAP:              2 | Reg. Domain:     0x10 |
|================= Capabilities ================|
| 802.11a Support:  no  | Turbo-A disabled: yes |
| 802.11b Support:  no  | Turbo-G disabled: yes |
| 802.11g Support:  yes | 2GHz XR disabled: yes |
| RFKill  Support:  yes | 5GHz XR disabled: yes |
| 32kHz   Crystal:  no  |                       |
\===============================================/

/=========================================================\
|          Calibration data common for all modes          |
|=========================================================|
|          CCK/OFDM gain delta:             1             |
|          CCK/OFDM power delta:            5             |
|          Scaled CCK delta:                5             |
|          2GHz Antenna gain:               0             |
|          5GHz Antenna gain:               0             |
|          Turbo 2W maximum dBm:           38             |
|          Target power start:          0x16e             |
|          EAR Start:                   0x1b8             |
\=========================================================/

/=========================================================\
|          Calibration data for 802.11g operation         |
|=========================================================|
| I power:              0x00 | Q power:              0x10 |
| Use fixed bias:       0x01 | Max turbo power:      0x26 |
| Max XR power:         0x1e | Switch Settling Time: 0x28 |
| Tx/Rx attenuation:    0x19 | TX end to XLNA On:    0x00 |
| TX end to XPA Off:    0x00 | TX end to XPA On:     0x0e |
| 62db Threshold:       0x1c | XLNA gain:            0x00 |
| XPD:                  0x01 | XPD gain:             0x0a |
| I gain:               0x00 | Tx/Rx margin:         0x01 |
| False detect backoff: 0x00 | Noise Floor Threshold:  -1 |
| ADC desired size:      -38 | PGA desired size:      -80 |
|=========================================================|
| Antenna control   0:  0x00 | Antenna control   1:  0x02 |
| Antenna control   2:  0x21 | Antenna control   3:  0x21 |
| Antenna control   4:  0x00 | Antenna control   5:  0x00 |
| Antenna control   6:  0x01 | Antenna control   7:  0x22 |
| Antenna control   8:  0x22 | Antenna control   9:  0x00 |
| Antenna control  10:  0x00 | Antenna control  11:  0x02 |
|=========================================================|
| Octave Band 0:           3 | db 0:                    3 |
| Octave Band 1:           4 | db 1:                    4 |
| Octave Band 2:           0 | db 2:                    0 |
| Octave Band 3:           0 | db 3:                    0 |
\=========================================================/
/============== Per rate power calibration ===========\
| Freq | 6-24Mbit/s | 36Mbit/s |  48Mbit/s | 54Mbit/s |
|======|============|==========|===========|==========|
| 2412 |    15.00   |  15.00   |   15.00   |  13.01   |
|======|============|==========|===========|==========|
| 2437 |    15.00   |  15.00   |   15.00   |  13.01   |
|======|============|==========|===========|==========|
| 2472 |    15.00   |  15.00   |   15.00   |  13.01   |
\=====================================================/
/=================== Per channel power calibration ====================\
| Freq | pwr_0 | pwr_1 | pwr_2 | pwr_3 |pwrx3_0|pwrx3_1|pwrx3_2|max_pwr|
|      | pcdac | pcdac | pcdac | pcdac | pcdac | pcdac | pcdac |       |
|======|=======|=======|=======|=======|=======|=======|=======|=======|
| 2412 | 25.00 | 25.00 |  0.00 | 25.00 |  0.00 |  0.00 | 29.01 | 25.00 |
|      | [112] | [112] | [112] | [112] |  [20] |  [35] |  [63] |       |
\======================================================================/

GPIO registers: CR 0x00000000, DO 0x00000000, DI 0x0000000b
STA_ID0: 00:1f:3a:a4:6f:43
STA_ID1: 0x0020436f, AP: 0, IBSS: 0, KeyCache Disable: 0
TIMER0: 0x00000030, TBTT:    48, TU: 0x108f0030
TIMER1: 0x0007ffff, DMAb: 65535, TU: 0x108effff (-49)
TIMER2: 0x01ffffff, SWBA: 65535, TU: 0x10bfffff (+3211215)
TIMER3: 0x00000031, ATIM:    49, TU: 0x108f0031 (+1)
TSF: 0x000000423940cd67, TSFTU: 20531, TU: 0x108e5033
BEACON: 0x00000000
LAST_TSTP: 0xb335b180


On Wed, 2008-06-11 at 08:06 +0300, Nick Kossifidis wrote:
> 2008/6/11 Geoffrey McRae <[EMAIL PROTECTED]>:
> > Hi everyone,
> >
> 
> Hello and thanks for the feedback ;-)
> 
> > I am new to hardware hacking and I am looking to get the AR2454 device
> > working in ath5k, however, due to my lack of understanding of the terms
> > used (ie, what is a PHY?), I am finding it very hard to reverse engineer
> > from trace dumps.
> >
> 
> I guess you refer to 2425 or 5424, there is no 2454 device. Can you
> please post the output of ath_info ?
> 
> > I have managed to add mmiotrace to a x86_64 2.6.25 kernel, and used the
> > latest hal from Sam L. to get madwifi working with this device. I have
> > also captured a complete trace and authentication with a WPA protected
> > gateway, and altered the decode perl script to work with the new output
> > format of mmiotrace.
> >
> 
> Can you please share the output with the rest of us ? We NEED traces ;-)
> 
> > I have also produced a dump from the latest ath5k, and I have noticed a
> > few things that seem wrong already...
> >
> > - The AR5K_PCICFG sleep register mask seems to be incorrect... ath5k is
> > checking against 0x1000 where my trace shows checking against 0x10000. I
> > have played around with a copy of ath5k and modified it to work this
> > way, and it seems to be correct (for ar2454)
> >
> 
> Yup i've also noticed that on other chips too but doesn't seem to be
> the problem, card seems to wake up fine, i'll recheck it (for now it
> works for me).
> 
> > - In my working trace, the value of AR5K_PHY_PLL should be set to 0xeb,
> > which is not the case for ath5k.
> >
> 
> You did an ath5k trace and it was different ?
> 
> It should be 0xeb, check out nic_wakeup, you should get for 2Ghz:
> 0x000000ab (AR5K_PHY_PLL_44MHZ_5212) | 0x00000040
> (AR5K_PHY_PLL_RF5112) = 0x000000eb
> 
> What value do you get ?
> 
> BTW what snapshot of ath5k are you using ? The one that's currently on
> compat-wireless and wireless-testing doesn't identify 2425 correctly
> so you might get a different value (0x00000019) is that the case ?
> 
> > - When madwifi does a radio init (i think thats what it does), it is
> > setting up PHY(17), but ath5k does not do this. I am not sure if this is
> > a problem as I dont know what a PHY is.
> >
> 
> It would be much easier if you shared the trace.
> PHY(17) is settling time register, we set it up during reset (maybe
> not in the same order).
> 
> > If anyone could direct me to some reading material, or send me some
> > info, it would be great as I would love to learn how to do this so I can
> > add the support myself.
> >
> > -Geoff
> >
> 
> Start by checking out the various chips we are working on...
> http://madwifi.org/wiki/Chipsets
> 
> For the rest check out the code, hw.c is mostly related to the MAC
> chip, phy.c is related to the PHY chip and initvals.c contains the
> initial settings for each chip combination (the static values we have
> to write on each reset).
> 
> A PHY chip btw is the chip that deals with the PHYsical layer (in our
> case the radio chip) ;-)
> 

_______________________________________________
ath5k-devel mailing list
ath5k-devel@lists.ath5k.org
https://lists.ath5k.org/mailman/listinfo/ath5k-devel

Reply via email to