Skip to contentSkip to conversation

cardbus/pcmcia/pci bridge problems?

DISCUSSION Paul Davis 2 participants 4 messages May 21, 2002

lore
Share & tools
lore

Paul Davis

author
#0 lore raw

I recently wrote the ALSA driver for the RME Hammerfall DSP, a high-end audio interface. The H-DSP comes in a variety of configurations, one of them involving a "pure" PCI interface, the other a PCMCIA card. The PCI interface works fine. Users with the PCMCIA card report major problems, the most representative of which are:

Case One (failure to make iomem available):
=========

Quoted 6 lines
May 16 09:54:57 satellite kernel: cs: cb_alloc(bus 3): vendor 0x10ee, device 
0x3fc5
May 16 09:54:57 satellite kernel: PCI: Failed to allocate resource 
0(d2400000-d20fffff) for 03:00.0
May 16 09:54:57 satellite kernel: PCI: Enabling device 03:00.0 (0080 -> 0082)
May 16 09:54:57 satellite cardmgr[258]: socket 0: CardBus hotplug device

Case Two (failure to allocate IRQ):
=========

Quoted 11 lines
May 16 15:15:32 badass-bukvic kernel: PCI: Found IRQ 5 for device
02:03.0
May 16 15:15:33 badass-bukvic kernel: Hammerfall memory allocator:
buffers allocated for 1 cards
May 16 15:15:33 badass-bukvic kernel: PCI: No IRQ known for interrupt
pin A of device . Please try using pci=biosirq.
May 16 15:15:33 badass-bukvic kernel: PCI: Setting latency timer of
device  to 64
May 16 15:15:33 badass-bukvic kernel: ALSA

../../alsa-kernel/pci/rme9652/hdsp.c:2984: unable to grab memory region 0x0-0x1447

In both cases, the error comes from cardbus/pcmcia/pci code that runs "below" and/or before the device driver itself.

The PCI profile of the device looks like:

----------------------------------------------------------------------
03:00.0 Multimedia audio controller: Xilinx, Inc.: Unknown device 3fc5 (rev 0a)
Control: I/O- Mem+ BusMaster- SpecCycle- MemWINV- VGASnoop- ParErr-
Stepping+ SERR- FastB2B-
Status: Cap- 66Mhz- UDF- FastB2B- ParErr- DEVSEL=medium >TAbort-
<TAbort- <MAbort- >SERR- <PERR-
Interrupt: pin A routed to IRQ 10
Region 0: [virtual] Memory at d2400000 (32-bit, non-prefetchable)
----------------------------------------------------------------------

It appears to me that there may be some problems with the current cardbus/pci bridge code in 2.4.X. can anyone with any involvement in this code fill me in on how well it is thought to be working, and what might give rise to either of the error cases shown above?

--p

#1 lore raw
Quoted 6 lines
Quoted 6 lines
May 16 15:15:32 badass-bukvic kernel: PCI: Found IRQ 5 for device
02:03.0
May 16 15:15:33 badass-bukvic kernel: Hammerfall memory allocator:
buffers allocated for 1 cards
May 16 15:15:33 badass-bukvic kernel: PCI: No IRQ known for interrupt

pin A of device . Please try using pci=biosirq.

The $PIR table in the BIOS provided no useful information on what IRQ to use, or we didn't know the IRQ router concerned to set it up.

Alan

author
#2 lore raw
Quoted 9 lines
Quoted 6 lines
Quoted 6 lines
May 16 15:15:32 badass-bukvic kernel: PCI: Found IRQ 5 for device
02:03.0
May 16 15:15:33 badass-bukvic kernel: Hammerfall memory allocator:
buffers allocated for 1 cards
May 16 15:15:33 badass-bukvic kernel: PCI: No IRQ known for interrupt

pin A of device . Please try using pci=biosirq.

The $PIR table in the BIOS provided no useful information on what IRQ to use, or we didn't know the IRQ router concerned to set it up.

alan: let me check what you're saying: despite the fact that lspci -vv shows the relevant information, there is still a problem?

the problem is either in the BIOS or its an issue with the kernel not knowing which IRQ router to use when setting up the interrupt? sorry to be repetitive, but i'm just trying to check that i fully understand this.

#3 lore raw
Quoted 10 lines
Quoted 2 lines

The $PIR table in the BIOS provided no useful information on what IRQ to use, or we didn't know the IRQ router concerned to set it up.

alan: let me check what you're saying: despite the fact that lspci -vv shows the relevant information, there is still a problem?

the problem is either in the BIOS or its an issue with the kernel not knowing which IRQ router to use when setting up the interrupt? sorry to be repetitive, but i'm just trying to check that i fully understand this.

There are two stages to IRQ routing

1. Knowing how INTA/B/C/D on the slot are wired to the INTA-D lines
on the PCI bus (its not 1-1)
2. Knowing how to drive the PCI irq routing hardware to route a
line to an ISA IRQ or to work out which it already goes to