Re: PCI bus and shared interrupts, proposal.(was:linux-kernel-digest V1 #824 )

Chel van Gennip (
Sun, 6 Apr 1997 13:58:21 +0100 (WETDST)

>> The SCSI drivers registers the IRQ with the SA_INTERRUPT flag,
>> the network driver without this flag, so the IRQ can not be
>> shared.
>This problem has been known for a year or so ... PCMCIA needs shared fast and
>slow interrupts.

I think the problem becomes more urgent with the new motherboards that
have a hardware link between the interrupt lines of the different PCI slots.
For me the problem is quite urgent. We just have fished the development of
a box. At the last moment we changed to a PPRO motherboard, to support ECC or
parity, and encounterd this new (to me) problem.

>A solution is available by reworking the existing fast/slow irq handlers, e.g.:
> 1. Walk the interrupt list for the signalled irq for FAST interrupts (irqs disabled)
> 2. enable irqs
> 3. if slow_irq_flag is set return (as for current fast irqs)
> 4. set a slow_irq_flag
> 5. walk the interrupt list for slow irqs
> 6. clear the slow_interrupt_flag
> 7. return (via signal handler code as for normal slow interrupts)

I think this is a direction to go, but I can not oversee all the consequences.
Maybe using the real-time Linux extensions might help to implement this.

>My questions on your proposal are:
>> Get a list of all available PCI IRQ's, assign the first one
>How to differentiate between ISA and PCI interrupts?
>> The pci_set_*_irq call should be called in all drivers, just
>> before the call of pcibios_read_config_byte() for the irq.
>How will you figure out the mapping from the INT lines to the interrupt
>controller IC inputs?

I allready mailed some interfaces to do so. But as some interrupt lines
can be tied together (randomly), it's no use changing the IRQ asignments.