diff options
author | Benjamin Herrenschmidt <benh@kernel.crashing.org> | 2006-10-08 23:27:28 -0400 |
---|---|---|
committer | Paul Mackerras <paulus@samba.org> | 2006-10-09 21:54:26 -0400 |
commit | 1e1b20a119ac45a290bbc6261f69a2a6a2cc064a (patch) | |
tree | 22cdf1c819a7b7fb2e475166b83682d9853a054d /arch/powerpc/platforms | |
parent | c10af8c38da7a0bc9010d6609237c1ab6d2da12c (diff) |
[POWERPC] Fix Maple secondary IDE interrupt
The IDE driver will pick up the PCI IRQ for both channels on Maple
despite the fact that it's in legacy mode. This works around it by
"hiding" the PCI IRQ of the AMD8111 IDE controller when it's configured
in legacy mode on the Maple platform, thus causing the driver to call
pci_get_legacy_ide_irq() which will return the correct interrupts for
both channels.
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
Diffstat (limited to 'arch/powerpc/platforms')
-rw-r--r-- | arch/powerpc/platforms/maple/pci.c | 17 |
1 files changed, 15 insertions, 2 deletions
diff --git a/arch/powerpc/platforms/maple/pci.c b/arch/powerpc/platforms/maple/pci.c index 8debae3aa3c9..63b4d1bff359 100644 --- a/arch/powerpc/platforms/maple/pci.c +++ b/arch/powerpc/platforms/maple/pci.c | |||
@@ -516,8 +516,21 @@ void __init maple_pcibios_fixup(void) | |||
516 | dev->irq = irq_create_mapping(NULL, 1); | 516 | dev->irq = irq_create_mapping(NULL, 1); |
517 | if (dev->irq != NO_IRQ) | 517 | if (dev->irq != NO_IRQ) |
518 | set_irq_type(dev->irq, IRQ_TYPE_LEVEL_LOW); | 518 | set_irq_type(dev->irq, IRQ_TYPE_LEVEL_LOW); |
519 | } else | 519 | continue; |
520 | pci_read_irq_line(dev); | 520 | } |
521 | |||
522 | /* Hide AMD8111 IDE interrupt when in legacy mode so | ||
523 | * the driver calls pci_get_legacy_ide_irq() | ||
524 | */ | ||
525 | if (dev->vendor == PCI_VENDOR_ID_AMD && | ||
526 | dev->device == PCI_DEVICE_ID_AMD_8111_IDE && | ||
527 | (dev->class & 5) != 5) { | ||
528 | dev->irq = NO_IRQ; | ||
529 | continue; | ||
530 | } | ||
531 | |||
532 | /* For all others, map the interrupt from the device-tree */ | ||
533 | pci_read_irq_line(dev); | ||
521 | } | 534 | } |
522 | 535 | ||
523 | DBG(" <- maple_pcibios_fixup\n"); | 536 | DBG(" <- maple_pcibios_fixup\n"); |