diff options
Diffstat (limited to 'arch/powerpc/platforms/maple/pci.c')
-rw-r--r-- | arch/powerpc/platforms/maple/pci.c | 47 |
1 files changed, 19 insertions, 28 deletions
diff --git a/arch/powerpc/platforms/maple/pci.c b/arch/powerpc/platforms/maple/pci.c index 63b4d1bff35..3a32deda765 100644 --- a/arch/powerpc/platforms/maple/pci.c +++ b/arch/powerpc/platforms/maple/pci.c | |||
@@ -502,38 +502,29 @@ static int __init add_bridge(struct device_node *dev) | |||
502 | } | 502 | } |
503 | 503 | ||
504 | 504 | ||
505 | void __init maple_pcibios_fixup(void) | 505 | void __devinit maple_pci_irq_fixup(struct pci_dev *dev) |
506 | { | 506 | { |
507 | struct pci_dev *dev = NULL; | 507 | DBG(" -> maple_pci_irq_fixup\n"); |
508 | 508 | ||
509 | DBG(" -> maple_pcibios_fixup\n"); | 509 | /* Fixup IRQ for PCIe host */ |
510 | 510 | if (u4_pcie != NULL && dev->bus->number == 0 && | |
511 | for_each_pci_dev(dev) { | 511 | pci_bus_to_host(dev->bus) == u4_pcie) { |
512 | /* Fixup IRQ for PCIe host */ | 512 | printk(KERN_DEBUG "Fixup U4 PCIe IRQ\n"); |
513 | if (u4_pcie != NULL && dev->bus->number == 0 && | 513 | dev->irq = irq_create_mapping(NULL, 1); |
514 | pci_bus_to_host(dev->bus) == u4_pcie) { | 514 | if (dev->irq != NO_IRQ) |
515 | printk(KERN_DEBUG "Fixup U4 PCIe IRQ\n"); | 515 | set_irq_type(dev->irq, IRQ_TYPE_LEVEL_LOW); |
516 | dev->irq = irq_create_mapping(NULL, 1); | 516 | } |
517 | if (dev->irq != NO_IRQ) | ||
518 | set_irq_type(dev->irq, IRQ_TYPE_LEVEL_LOW); | ||
519 | continue; | ||
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 | 517 | ||
532 | /* For all others, map the interrupt from the device-tree */ | 518 | /* Hide AMD8111 IDE interrupt when in legacy mode so |
533 | pci_read_irq_line(dev); | 519 | * the driver calls pci_get_legacy_ide_irq() |
520 | */ | ||
521 | if (dev->vendor == PCI_VENDOR_ID_AMD && | ||
522 | dev->device == PCI_DEVICE_ID_AMD_8111_IDE && | ||
523 | (dev->class & 5) != 5) { | ||
524 | dev->irq = NO_IRQ; | ||
534 | } | 525 | } |
535 | 526 | ||
536 | DBG(" <- maple_pcibios_fixup\n"); | 527 | DBG(" <- maple_pci_irq_fixup\n"); |
537 | } | 528 | } |
538 | 529 | ||
539 | static void __init maple_fixup_phb_resources(void) | 530 | static void __init maple_fixup_phb_resources(void) |