Skip to contentSkip to conversation

OSK5912 and CF and network broken?

DISCUSSION Tom Rini 3 participants 9 messages Mar 15, 2006 – Mar 22, 2006

lore
Share & tools
lore

Tom Rini

author
#0 lore raw

Hello. I'm trying to use current linux-omap-2.6 (source.mvista.com one) git with the omap_osk_5912_defconfig and with U-Boot 1.1.4 release (+ 2 patches from this list). I can bring the board up just fine but when I insert a CF device I see:
pccard: PCMCIA card inserted into slot 0
pcmcia: registering new device pcmcia0.0
NETDEV WATCHDOG: eth0: transmit timed out
...
NETDEV WATCHDOG: eth0: transmit timed out
pccard: card ejected from slot 0

Has anyone seen this before? Or should I just looking at the interrupt routes? I'm assuming that the board does support me using both CF and network at the same time. Thanks!

Signature · 2 lines
Tom Rini
http://gate.crashing.org/~trini/
#1 lore raw
Quoted 11 lines · Tom Rini

Hello. I'm trying to use current linux-omap-2.6 (source.mvista.com one) git with the omap_osk_5912_defconfig and with U-Boot 1.1.4 release (+ 2 patches from this list). I can bring the board up just fine but when I insert a CF device I see:
pccard: PCMCIA card inserted into slot 0
pcmcia: registering new device pcmcia0.0
NETDEV WATCHDOG: eth0: transmit timed out
...
NETDEV WATCHDOG: eth0: transmit timed out
pccard: card ejected from slot 0

Quoted 3 lines

Has anyone seen this before? Or should I just looking at the interrupt routes? I'm assuming that the board does support me using both CF and network at the same time. Thanks!

This should not happen... It sounds like an issue with the flash bus timings. Might be worth grepping for EMIFS_CS values.

Tony

author
#2 lore raw
Quoted 12 lines · Tony Lindgren
Quoted 11 lines · Tom Rini

Hello. I'm trying to use current linux-omap-2.6 (source.mvista.com one) git with the omap_osk_5912_defconfig and with U-Boot 1.1.4 release (+ 2 patches from this list). I can bring the board up just fine but when I insert a CF device I see:
pccard: PCMCIA card inserted into slot 0
pcmcia: registering new device pcmcia0.0
NETDEV WATCHDOG: eth0: transmit timed out
...
NETDEV WATCHDOG: eth0: transmit timed out
pccard: card ejected from slot 0

Quoted 6 lines
Quoted 3 lines

Has anyone seen this before? Or should I just looking at the interrupt routes? I'm assuming that the board does support me using both CF and network at the same time. Thanks!

This should not happen... It sounds like an issue with the flash bus timings. Might be worth grepping for EMIFS_CS values.

Er, this?
linux-omap-2.6]$ grep -r EMIFS_CS arch/arm include/asm-arm
arch/arm/mach-omap1/board-osk.c:#define EMIFS_CS3_VAL (0x88013141)

arch/arm/mach-omap1/board-osk.c:        if (EMIFS_CCS(3) != EMIFS_CS3_VAL)
arch/arm/mach-omap1/board-osk.c:                EMIFS_CCS(3) = EMIFS_CS3_VAL;

include/asm-arm/arch-omap/tc.h:#define EMIFS_CS0_CONFIG (TCMIF_BASE + 0x10) include/asm-arm/arch-omap/tc.h:#define EMIFS_CS1_CONFIG (TCMIF_BASE + 0x14) include/asm-arm/arch-omap/tc.h:#define EMIFS_CS2_CONFIG (TCMIF_BASE + 0x18) include/asm-arm/arch-omap/tc.h:#define EMIFS_CS3_CONFIG (TCMIF_BASE + 0x1c)
include/asm-arm/arch-omap/tc.h:#define EMIFS_CCS(n) __REG32(EMIFS_CS0_CONFIG + (4 * (n)))

Signature · 2 lines
Tom Rini
http://gate.crashing.org/~trini/
#3 lore raw
Quoted 23 lines · Tom Rini
Quoted 12 lines · Tony Lindgren
Quoted 11 lines · Tom Rini

Hello. I'm trying to use current linux-omap-2.6 (source.mvista.com one) git with the omap_osk_5912_defconfig and with U-Boot 1.1.4 release (+ 2 patches from this list). I can bring the board up just fine but when I insert a CF device I see:
pccard: PCMCIA card inserted into slot 0
pcmcia: registering new device pcmcia0.0
NETDEV WATCHDOG: eth0: transmit timed out
...
NETDEV WATCHDOG: eth0: transmit timed out
pccard: card ejected from slot 0

Quoted 6 lines
Quoted 3 lines

Has anyone seen this before? Or should I just looking at the interrupt routes? I'm assuming that the board does support me using both CF and network at the same time. Thanks!

This should not happen... It sounds like an issue with the flash bus timings. Might be worth grepping for EMIFS_CS values.

Er, this?
linux-omap-2.6]$ grep -r EMIFS_CS arch/arm include/asm-arm
arch/arm/mach-omap1/board-osk.c:#define EMIFS_CS3_VAL (0x88013141)

Quoted 7 lines
arch/arm/mach-omap1/board-osk.c:        if (EMIFS_CCS(3) != EMIFS_CS3_VAL)
arch/arm/mach-omap1/board-osk.c:                EMIFS_CCS(3) = EMIFS_CS3_VAL;

include/asm-arm/arch-omap/tc.h:#define EMIFS_CS0_CONFIG (TCMIF_BASE + 0x10) include/asm-arm/arch-omap/tc.h:#define EMIFS_CS1_CONFIG (TCMIF_BASE + 0x14) include/asm-arm/arch-omap/tc.h:#define EMIFS_CS2_CONFIG (TCMIF_BASE + 0x18) include/asm-arm/arch-omap/tc.h:#define EMIFS_CS3_CONFIG (TCMIF_BASE + 0x1c)
include/asm-arm/arch-omap/tc.h:#define EMIFS_CCS(n) __REG32(EMIFS_CS0_CONFIG + (4 * (n)))

Yes, and then also some settings are done in drivers/pcmcia/omap_cf.c. Maybe omap_cf.c undoes some EMIFS_CS settings done in board-osk.c?

Tony

author
#4 lore raw
Quoted 32 lines · Tony Lindgren
Quoted 23 lines · Tom Rini
Quoted 12 lines · Tony Lindgren
Quoted 11 lines · Tom Rini

Hello. I'm trying to use current linux-omap-2.6 (source.mvista.com one) git with the omap_osk_5912_defconfig and with U-Boot 1.1.4 release (+ 2 patches from this list). I can bring the board up just fine but when I insert a CF device I see:
pccard: PCMCIA card inserted into slot 0
pcmcia: registering new device pcmcia0.0
NETDEV WATCHDOG: eth0: transmit timed out
...
NETDEV WATCHDOG: eth0: transmit timed out
pccard: card ejected from slot 0

Quoted 6 lines
Quoted 3 lines

Has anyone seen this before? Or should I just looking at the interrupt routes? I'm assuming that the board does support me using both CF and network at the same time. Thanks!

This should not happen... It sounds like an issue with the flash bus timings. Might be worth grepping for EMIFS_CS values.

Er, this?
linux-omap-2.6]$ grep -r EMIFS_CS arch/arm include/asm-arm
arch/arm/mach-omap1/board-osk.c:#define EMIFS_CS3_VAL (0x88013141)

Quoted 7 lines
arch/arm/mach-omap1/board-osk.c:        if (EMIFS_CCS(3) != EMIFS_CS3_VAL)
arch/arm/mach-omap1/board-osk.c:                EMIFS_CCS(3) = EMIFS_CS3_VAL;

include/asm-arm/arch-omap/tc.h:#define EMIFS_CS0_CONFIG (TCMIF_BASE + 0x10) include/asm-arm/arch-omap/tc.h:#define EMIFS_CS1_CONFIG (TCMIF_BASE + 0x14) include/asm-arm/arch-omap/tc.h:#define EMIFS_CS2_CONFIG (TCMIF_BASE + 0x18) include/asm-arm/arch-omap/tc.h:#define EMIFS_CS3_CONFIG (TCMIF_BASE + 0x1c)
include/asm-arm/arch-omap/tc.h:#define EMIFS_CCS(n) __REG32(EMIFS_CS0_CONFIG + (4 * (n)))

Quoted 2 lines

Yes, and then also some settings are done in drivers/pcmcia/omap_cf.c. Maybe omap_cf.c undoes some EMIFS_CS settings done in board-osk.c?

Yes, it does change CS2:
omap_cf: cs2, previous ccs ff80fff3 acs 00000002
omap_cf: cs2, current ccs 0004a1b3 acs 00000000

With the comment:
/* NOTE: better EMIFS setup might support more cards; but the
* TRM only shows how to affect regular flash signals, not their
* CF/PCMCIA variants...
*/

Signature · 2 lines
Tom Rini
http://gate.crashing.org/~trini/
#5 lore raw
In reply to Tom Rini
Quoted 3 lines · Tom Rini

Has anyone seen this before? Or should I just looking at the interrupt routes? I'm assuming that the board does support me using both CF and network at the same time. Thanks!

Yes, board supports both, CF and network. However, OSK CF hardware is limited and is really troublesome.

But using recent git without any special patches I get no transmit timeouts:

# pccard: PCMCIA card inserted into slot 0
pcmcia: registering new device pcmcia0.0

# ping 192.0.0.1
PING 192.0.0.1 (192.0.0.1): 56 data bytes
64 bytes from 192.0.0.1: icmp_seq=0 ttl=64 time=1.0 ms
64 bytes from 192.0.0.1: icmp_seq=1 ttl=64 time=0.8 ms

--- 192.0.0.1 ping statistics ---
2 packets transmitted, 2 packets received, 0% packet loss round-trip min/avg/max = 0.8/0.9/1.0 ms

# cp /mnt/nfs/foo.mp3 /dev/null
...
# pccard: card ejected from slot 0

=> No timeouts

Kernel configuration:

#
# ATA/ATAPI/MFM/RLL support
#
CONFIG_IDE=m
CONFIG_BLK_DEV_IDE=m

#
# Please see Documentation/ide.txt for help/info on IDE drives #
# CONFIG_BLK_DEV_IDE_SATA is not set CONFIG_BLK_DEV_IDEDISK=m
# CONFIG_IDEDISK_MULTI_MODE is not set CONFIG_BLK_DEV_IDECS=m
# CONFIG_BLK_DEV_IDECD is not set
# CONFIG_BLK_DEV_IDETAPE is not set
# CONFIG_BLK_DEV_IDEFLOPPY is not set
# CONFIG_BLK_DEV_IDESCSI is not set
# CONFIG_IDE_TASK_IOCTL is not set

#
# PCCARD (PCMCIA/CardBus) support
#
CONFIG_PCCARD=m
# CONFIG_PCMCIA_DEBUG is not set
CONFIG_PCMCIA=m
CONFIG_PCMCIA_LOAD_CIS=y
CONFIG_PCMCIA_IOCTL=y

#
# PC-card bridges
#
CONFIG_OMAP_CF=m

However, seems that my cardmgr is configured wrong again, but this is another issue:

# cardmgr
cardmgr[978]: watching 1 socket
cardmgr[978]: could not adjust resource: IO ports 0xc00-0xcff: Function not implemented
cardmgr[978]: could not adjust resource: IO ports 0x800-0x8ff: Function not implemented
cardmgr[978]: could not adjust resource: IO ports 0x100-0x4ff: Function not implemented
cardmgr[978]: could not adjust resource: memory 0xc0000-0xfffff: Function not implemented
cardmgr[978]: could not adjust resource: memory 0x60000000-0x60ffffff: Function not implemented
cardmgr[978]: could not adjust resource: memory 0xa0000000-0xa0ffffff: Function not implemented
cardmgr[978]: could not adjust resource: IO ports 0xa00-0xaff: Function not implemented
# pccard: PCMCIA card inserted into slot 0
cardmgr[979]: socket 0: Anonymous Memory
cardmgr[979]: executing: 'modprobe memory_cs 2>&1'
cardmgr[979]: + modprobe: module memory_cs not found.
cardmgr[979]: + modprobe: failed to load module memory_cs
cardmgr[979]: modprobe exited with status 1
cardmgr[979]: module /lib/modules/2.6.16-rc5-omap1/pcmcia/memory_cs.o not available
cardmgr[979]: bind 'memory_cs' to socket 0 failed: Invalid argument

Best regards

Dirk

author
#6 lore raw
Quoted 7 lines · Dirk Behme
Quoted 3 lines · Tom Rini

Has anyone seen this before? Or should I just looking at the interrupt routes? I'm assuming that the board does support me using both CF and network at the same time. Thanks!

Yes, board supports both, CF and network. However, OSK CF hardware is limited and is really troublesome.

I wonder if my board is just more troublesome than most. If I turned off network (and used a ramdisk for userspace) I then got to the point of:

pccard: PCMCIA card inserted into slot 0
pcmcia: registering new device pcmcia0.0
hdb: probing with STATUS(0x00) instead of ALTSTATUS(0x51)
hdb: probing with STATUS(0x00) instead of ALTSTATUS(0x51)
hdb: probing with STATUS(0x00) instead of ALTSTATUS(0x51)
hdb: probing with STATUS(0x00) instead of ALTSTATUS(0x51)
hdb: probing with STATUS(0x00) instead of ALTSTATUS(0x51)
hdb: probing with STATUS(0x00) instead of ALTSTATUS(0x51)
hdb: probing with STATUS(0x00) instead of ALTSTATUS(0x51)
hdb: probing with STATUS(0x00) instead of ALTSTATUS(0x51)
hdb: probing with STATUS(0x00) instead of ALTSTATUS(0x51)
hdb: probing with STATUS(0x00) instead of ALTSTATUS(0x51)
ide-cs: ide_register() at 0xc2852000 & 0xc285200e, irq 222 failed

with an old 16MB CF card. With my 2.2GB microdrive I get more of the messages, but the same result. FWIW, u-boot won't load if the MD is inserted, but will if the CF is.

But perhaps I need a better cardmgr options file? I don't have anything board-specific in mine. Thanks!

Signature · 2 lines
Tom Rini
http://gate.crashing.org/~trini/
#7 lore raw
Quoted 26 lines · Tom Rini
Quoted 7 lines · Dirk Behme
Quoted 3 lines · Tom Rini

Has anyone seen this before? Or should I just looking at the interrupt routes? I'm assuming that the board does support me using both CF and network at the same time. Thanks!

Yes, board supports both, CF and network. However, OSK CF hardware is limited and is really troublesome.

I wonder if my board is just more troublesome than most. If I turned off network (and used a ramdisk for userspace) I then got to the point of:

pccard: PCMCIA card inserted into slot 0
pcmcia: registering new device pcmcia0.0
hdb: probing with STATUS(0x00) instead of ALTSTATUS(0x51)
hdb: probing with STATUS(0x00) instead of ALTSTATUS(0x51)
hdb: probing with STATUS(0x00) instead of ALTSTATUS(0x51)
hdb: probing with STATUS(0x00) instead of ALTSTATUS(0x51)
hdb: probing with STATUS(0x00) instead of ALTSTATUS(0x51)
hdb: probing with STATUS(0x00) instead of ALTSTATUS(0x51)
hdb: probing with STATUS(0x00) instead of ALTSTATUS(0x51)
hdb: probing with STATUS(0x00) instead of ALTSTATUS(0x51)
hdb: probing with STATUS(0x00) instead of ALTSTATUS(0x51)
hdb: probing with STATUS(0x00) instead of ALTSTATUS(0x51)
ide-cs: ide_register() at 0xc2852000 & 0xc285200e, irq 222 failed

Quoted 6 lines

with an old 16MB CF card. With my 2.2GB microdrive I get more of the messages, but the same result. FWIW, u-boot won't load if the MD is inserted, but will if the CF is.

But perhaps I need a better cardmgr options file? I don't have anything board-specific in mine. Thanks!

I believe there may be some different timings needed depending on the OSK revision.

Tony

#8 lore raw
Quoted 8 lines · [email protected] wrote:
Quoted 4 lines · Tom Rini
Quoted 2 lines

Tom Rini wrote:

But perhaps I need a better cardmgr options file? I don't have anything board-specific in mine. Thanks!

I believe there may be some different timings needed depending on the OSK revision.

Yes, that may be possible. But this doesn't explain why on my board (where hopefully timing doesn't change ;) ) it worked in the past, then was partly broken and now doesn't work any more ;(

Dirk