]> git.baikalelectronics.ru Git - kernel.git/commit
[IA64] Clear IRQ affinity when unregistered
authorAlex Williamson <alex.williamson@hp.com>
Thu, 25 Jan 2007 05:48:04 +0000 (22:48 -0700)
committerTony Luck <tony.luck@intel.com>
Mon, 5 Feb 2007 22:09:51 +0000 (14:09 -0800)
commit09c76cf532886b4a96daa08b93816f61a74d93fd
treebfcdcefad73d32948fe4626af8720fc8c174b4a5
parent79075087c58627cf5017212747b7a1875f165472
[IA64] Clear IRQ affinity when unregistered

When we offline a CPU, migrate_irqs() tries to determine whether the
affinity bits of the IRQ descriptor match any of the remaining online
CPUs.  If not, it fixes up the interrupt to point somewhere else.
Unfortunately, if an IRQ is unregistered the IRQ descriptor may still
have affinity to the CPU being offlined, but the no_irq_chip handler
doesn't provide a set_affinity function.  This causes us to hit the
WARN_ON in migrate_irqs().

The easiest solution seems to be setting all the bits in the affinity
mask when the last interrupt is removed from the vector.  I hit this on
an older kernel with Xen/ia64 using driver domains (so it probably needs
more testing on upstream).  Xen essentially uses the bind/unbind
interface in sysfs to unregister a device from a driver and thus
unregister the interrupt.

Signed-off-by: Alex Williamson <alex.williamson@hp.com>
Signed-off-by: Tony Luck <tony.luck@intel.com>
arch/ia64/kernel/iosapic.c