Libertas with if_spi on pxa270
Uli Luckas
u.luckas at road.de
Tue Jan 27 14:44:01 EST 2009
On Tuesday, 27. January 2009, Mike Rapoport wrote:
> Dan,
>
> Dan Williams wrote:
> > On Mon, 2009-01-26 at 18:24 +0200, Mike Rapoport wrote:
> >> Dan Williams wrote:
> >>> On Mon, 2009-01-26 at 16:58 +0200, Mike Rapoport wrote:
> >>>> Hi,
> >>>>
> >>>> Have anybody tried to use 8686 with G-SPI on PXA270?
> >>>> I've merged libertas-related changes from wireless-testing tree on top
> >>>> of 2.6.29-rc2, added a "libertas_spi" device to my platform code, but
> >>>> all I could get from the if_spi was "libertas: Can't read bus mode
> >>>> register." :(
> >>>
> >>> Have you set up the Chip Select stuff correctly for your board (see
> >>> gpio_cs in the platform data)? That seems to be board-dependent and
> >>> there's not a good generic way of doing this in the current kernel
> >>> sources.
> >>>
> >>> That error is the first error that will get reported when the driver
> >>> actually tries to talk to the card, which requires that the Chip Select
> >>> stuff be set up correctly. If you think you've got that already set
> >>> up, can you manually inspect whether or not the libertas device has
> >>> actually been selected on the board?
> >>
> >> The first thing I've done was to recheck GPIO setup and platform_data
> >> for all SPI related stuff.
> >> I've even inserted GPIO setup function at the very beginning of
> >> if_spi_probe. The Marvell proprietary driver works well on the same
> >> board and exactly same GPIOs setup.
> >
> > Ok, Colin McCabe will probably need to get involved here then since he
> > wrote those bits :)
>
> You were right about possible problems with my board setup. The 8686
> requires SPI clock pin to be high at power up to start with G-SPI rather
> than SDIO. That part was missing from my board setup.
> Still I needed to alter the if_spi.c to make it work.
>
Does that mean, you got it working on PXA? Mine won't work.
On pxa270, kernel 2.6.27.3 + "gspi patch" + "16bit/word spi mode" I get the
following log:
Jan 26 19:39:44 [kernel] [ 242.422220] libertas_spi: Libertas SPI driver
Jan 26 19:39:44 [kernel] [ 242.425066] firmware: requesting
libertas/gspi8686_hlp.bin
Jan 26 19:39:45 [kernel] [ 243.089646] firmware: requesting
libertas/gspi8686.bin
Jan 26 19:39:49 [kernel] [ 247.049868] libertas: command 0x0003 timed out
Jan 26 19:39:49 [kernel] [ 247.049937] libertas: requeueing command 0x0003
due to timeout (#1)
Jan 26 19:39:49 [kernel] [ 247.051820] libertas: Received result 0 to command
3 after 1 retries
Jan 26 19:39:49 [kernel] [ 247.051989] libertas: 00:15:af:3a:8a:9a, fw
9.70.10p0, cap 0x00000303
Jan 26 19:39:49 [kernel] [ 247.057863] libertas: Received CMD_RESP with
invalid sequence 1 (expected 2)
Jan 26 19:39:52 [kernel] [ 250.049932] libertas: command 0x0028 timed out
Jan 26 19:39:52 [kernel] [ 250.050016] libertas: requeueing command 0x0028
due to timeout (#1)
Jan 26 19:39:52 [kernel] [ 250.051814] libertas: Received result 0 to command
28 after 1 retries
Jan 26 19:39:52 [kernel] [ 250.053530] libertas: Received CMD_RESP with
invalid sequence 2 (expected 3)
Jan 26 19:39:55 [kernel] [ 253.049850] libertas: command 0x001d timed out
Jan 26 19:39:55 [kernel] [ 253.049919] libertas: requeueing command 0x001d
due to timeout (#1)
Jan 26 19:39:55 [kernel] [ 253.051795] libertas: Received result 0 to command
1d after 1 retries
Jan 26 19:39:55 [kernel] [ 253.053982] libertas: Received CMD_RESP with
invalid sequence 3 (expected 4)
Jan 26 19:39:58 [kernel] [ 256.049914] libertas: command 0x00a3 timed out
Jan 26 19:39:58 [kernel] [ 256.050000] libertas: requeueing command 0x00a3
due to timeout (#1)
Jan 26 19:39:58 [kernel] [ 256.052128] libertas: Received result 2 to command
a3 after 1 retries
Jan 26 19:39:58 [kernel] [ 256.052278] libertas: PREP_CMD: command 0x00a3
failed: 2
Jan 26 19:39:58 [kernel] [ 256.054505] libertas: Received CMD_RESP with
invalid sequence 4 (expected 5)
Jan 26 19:40:01 [kernel] [ 259.049833] libertas: command 0x00a3 timed out
Jan 26 19:40:01 [kernel] [ 259.049901] libertas: requeueing command 0x00a3
due to timeout (#1)
Jan 26 19:40:01 [kernel] [ 259.052018] libertas: Received result 2 to command
a3 after 1 retries
Jan 26 19:40:01 [kernel] [ 259.052146] libertas: PREP_CMD: command 0x00a3
failed: 2
Jan 26 19:40:01 [kernel] [ 259.052205] libertas: eth0: Marvell WLAN 802.11
adapter
Any idea what could be going wrong here?
Uli
--
------- ROAD ...the handyPC Company - - - ) ) )
Uli Luckas
Head of Software Development
ROAD GmbH
Bennigsenstr. 14 | 12159 Berlin | Germany
fon: +49 (30) 230069 - 62 | fax: +49 (30) 230069 - 69
url: www.road.de
Amtsgericht Charlottenburg: HRB 96688 B
Managing director: Hans-Peter Constien
More information about the libertas-dev
mailing list