aboutsummaryrefslogtreecommitdiff
path: root/arch/powerpc/kernel
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@g5.osdl.org>2006-10-08 15:38:22 -0700
committerLinus Torvalds <torvalds@g5.osdl.org>2006-10-08 15:38:22 -0700
commite24bb60e11e3fe9858b71874a4ac59333adbc4fc (patch)
tree948763fe4c7c173e0b5ac6fa1452c8a55c47bb38 /arch/powerpc/kernel
parent0bae89ec8b1519dae67036637942f5b5bbaa9424 (diff)
Revert "[POWERPC] Don't get PCI IRQ from OF for devices with no IRQ"
This reverts commit 41550c5128150175197257b6ceab2cd50dea7b51. Quoth Ben Herrenschmidt: "Please revert this one for now. It seems to break G5s :( Looks like PCI cells inside Apple IO ASICs don't have a PCI_INTERRUPT_LINE set. I need to figure out a better fix." Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'arch/powerpc/kernel')
-rw-r--r--arch/powerpc/kernel/prom_parse.c17
1 files changed, 6 insertions, 11 deletions
diff --git a/arch/powerpc/kernel/prom_parse.c b/arch/powerpc/kernel/prom_parse.c
index 17fcb4842fe..603dff3ad62 100644
--- a/arch/powerpc/kernel/prom_parse.c
+++ b/arch/powerpc/kernel/prom_parse.c
@@ -914,17 +914,6 @@ int of_irq_map_pci(struct pci_dev *pdev, struct of_irq *out_irq)
u8 pin;
int rc;
- /* We need to first check if the PCI device has a PCI interrupt at all
- * since we have cases where the device-node might expose non-PCI
- * interrupts, but the device has no PCI interrupt to it
- */
- rc = pci_read_config_byte(pdev, PCI_INTERRUPT_PIN, &pin);
- if (rc != 0)
- return rc;
- /* No pin, exit */
- if (pin == 0)
- return -ENODEV;
-
/* Check if we have a device node, if yes, fallback to standard OF
* parsing
*/
@@ -936,6 +925,12 @@ int of_irq_map_pci(struct pci_dev *pdev, struct of_irq *out_irq)
* interrupt spec. we assume #interrupt-cells is 1, which is standard
* for PCI. If you do different, then don't use that routine.
*/
+ rc = pci_read_config_byte(pdev, PCI_INTERRUPT_PIN, &pin);
+ if (rc != 0)
+ return rc;
+ /* No pin, exit */
+ if (pin == 0)
+ return -ENODEV;
/* Now we walk up the PCI tree */
lspec = pin;