]> git.neil.brown.name Git - history.git/commit
[PATCH] ia64: bug w/ shared interrupts
authorAlex Williamson <alex.williamson@hp.com>
Mon, 26 Apr 2004 07:13:52 +0000 (00:13 -0700)
committerDavid Mosberger <davidm@tiger.hpl.hp.com>
Mon, 26 Apr 2004 07:13:52 +0000 (00:13 -0700)
commitd88ad34ee4d238705394a2b94cdfea4c572ec9ef
tree271bca190f9c9c68abeb44e96a2facb3584f7b4c
parent8df2fe60a1377188968b89bbac977df6eeda2f65
[PATCH] ia64: bug w/ shared interrupts

I just ran into a bug introduced by the most recent iosapic.c patch.
The scenario is a builtin driver is up and running happily.  A module
loads for a devices that happens to share the same interrupt vector,
in this case a network driver.  The module calls pci_enable_device()
as it should, which eventually lands in iosapic_enable_intr().  We
then proceed to mask the interrupt and kill the device that's already
running.  As a bonus, request_interrupt() doesn't fix the problem
because we only call the startup for the interrupt handler on the
first action attached to the interrupt.

I think the best way out of this is simply to detect when an action is
already attached to a vector and leave it alone.  This also prevents
interrupts from moving to other cpus (on boxes w/o irq redirection)
for no good reason.
arch/ia64/kernel/iosapic.c