Subject: interrupt sharing problem?
To: None <port-amd64@netbsd.org>
From: Matthias Drochner <M.Drochner@fz-juelich.de>
List: port-amd64
Date: 02/12/2004 19:37:49
Hi -
I'm getting problems with a nice dual Opteron system as soon
as I plug an (adaptec) SCSI controller in. The box hangs sooner
or later; the "bge", "fxp" and "viaide" complain about missed
interrupts and timeouts.
There is nothing connected to the SCSI adapter yet - it seems
that just the different interrupt routing caused by its mere
presence triggers the problem.
Indeed, with the "ahc" plugged in I'm getting:

$ /sbin/dmesg |grep ioapic
ioapic0 at mainbus0 apid 2 (I/O APIC)
ioapic0: pa 0xfec00000, version 11, 24 pins
ioapic1 at mainbus0 apid 3 (I/O APIC)
ioapic1: pa 0xfebff000, version 11, 4 pins
ioapic2 at mainbus0 apid 4 (I/O APIC)
ioapic2: pa 0xfebfe000, version 11, 4 pins
ohci0: interrupting at ioapic0 pin 19 (irq 10)
ohci1: interrupting at ioapic0 pin 19 (irq 10)
satalink0: using ioapic0 pin 19 (irq 10) for native-PCI interrupt
fxp0: interrupting at ioapic0 pin 18 (irq 11)
viaide0: primary channel interrupting at ioapic0 pin 14 (irq 14)
viaide0: secondary channel interrupting at ioapic0 pin 15 (irq 15)
bge0: interrupting at ioapic1 pin 0 (irq 5)
bge1: interrupting at ioapic1 pin 1 (irq 9)
ahc0: interrupting at ioapic2 pin 1 (irq 9)
ioapic2: enabling
ioapic1: enabling
ioapic0: enabling

See the "bge1" and "ahc0" lines -- interrupts from 2 different
ioasics routed to the same CPU interrupt.

For comparision, without that card:

$ /sbin/dmesg |grep ioapic
ioapic0 at mainbus0 apid 2 (I/O APIC)
ioapic0: pa 0xfec00000, version 11, 24 pins
ioapic1 at mainbus0 apid 3 (I/O APIC)
ioapic1: pa 0xfebff000, version 11, 4 pins
ioapic2 at mainbus0 apid 4 (I/O APIC)
ioapic2: pa 0xfebfe000, version 11, 4 pins
ohci0: interrupting at ioapic0 pin 19 (irq 10)
ohci1: interrupting at ioapic0 pin 19 (irq 10)
satalink0: using ioapic0 pin 19 (irq 10) for native-PCI interrupt
fxp0: interrupting at ioapic0 pin 18 (irq 11)
viaide0: primary channel interrupting at ioapic0 pin 14 (irq 14)
viaide0: secondary channel interrupting at ioapic0 pin 15 (irq 15)
bge0: interrupting at ioapic1 pin 0 (irq 5)
bge1: interrupting at ioapic1 pin 1 (irq 9)
ioapic2: enabling
ioapic1: enabling
ioapic0: enabling

Any clues what to do here?

best regards
Matthias