Skip to contentSkip to conversation

Backport Via IRQ mask fix

PATCH New Herbert Xu 1 participant 1 message Oct 5, 2004

lore
Share & tools
lore

Herbert Xu

author
#0 lore raw

PATCH 1/1 Backport Via IRQ mask fix

Hi Marcelo:

Here is a backport of the Via APIC IRQ mask fix that Al Viro made to 2.6. This is his original description:

# ChangeSet
# 2004/06/23 10:55:18-07:00 [email protected]
# [PATCH] bug in V-link handling (arch/i386/pci/irq.c)
#

#   	Via southbridges use register 0x3c of the on-board devices (USB and
#   AC97) to control interrupt routing for those.  In drivers/pci/quirks.c we
#   set it correctly (dev->irq & 15).  However, in pirq_enable_irq() where the
#   second half of that stuff lives, we forget to apply the mask.
#   
#   	That's what causes problems with ioapic on via motherboards in 2.6.
#   One-liner below ACKed by Alan, verified on via-based boxen here, obviously
#   doesn't affect non-via ones (we only set interrupt_line_quirk for via
#   chipsets). 

Cheers,

Signature · 4 lines
Visit Openswan at http://www.openswan.org/
Email: Herbert Xu ~{PmV>HI~} <[email protected]>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt

===== arch/i386/kernel/pci-irq.c 1.29 vs edited =====

arch/i386/kernel/pci-irq.c +1 -1
@@ -1129,6 +1129,6 @@
 	/* VIA bridges use interrupt line for apic/pci steering across
 	   the V-Link */
 	else if (interrupt_line_quirk)
-		pci_write_config_byte(dev, PCI_INTERRUPT_LINE, dev->irq);
+		pci_write_config_byte(dev, PCI_INTERRUPT_LINE, dev->irq & 15);
 		
 }