AR6000 driver failed on probe stage
dongas86 at gmail.com
Tue Apr 7 14:46:27 CEST 2009
2009/3/28 dongas <dongas86 at gmail.com>:
> After digging into the code, i found that in bmiBufferSend function in bmi.c,
> the driver will try to repeatly read the COUNT_DEC register of the
> card until the register value read back is Non-zero and then the following
> steps can go on.
> But the value returned from register was alway zero , so ar6000 driver
> hanged there and keeped doing almost the infinit loop
> Why the driver can not read a non-zero value from COUNT_DEC register
> as it wanted?
After debugging i found that the ar6000 driver failed when it was
trying to read target version via BMI request of ar6000 in the routine
BMIGetTargetInfo because it was unable to get a BMI command credit(by
reading CONUTER_DEC register) for the next BMI request according to
the BMI flow control.
I think if the target(ar6000) initialized successful before after the
host enabled it, the target should have initially provided one command
credit to host according to the datasheet, but it hadn’t. (if wrong
pls correct me )
(The target is enabled by the CMD52 to write to ENABLE BIT of CCCR
register of card.
Once the target is enabled, it executes firmware that initializes SoC
and software states.)
So the driver repeatly tried to get this command credit and hanged there.
I went through some ar6001 related specs/documents, but still havn't
got the key of this issue that why the target failed to provided one
command credit to after it was enabled by host?
I guess the target failed to initailize itself or worked inproperly
but don't know which reason might cause it failed.
Now only one thing i can make sure is that wifi card is on I/O Ready
state after host enables it by checing CCCR register.
Any ideas about this issue?
More information about the openmoko-kernel