diff options
author | Linus Torvalds <torvalds@g5.osdl.org> | 2006-10-07 13:52:00 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-10-07 13:52:00 -0400 |
commit | ba00003aa83a61b615542dd66f5af8fb4a7cee1d (patch) | |
tree | 013dde7e89730e54433aa40b5e9d67997931aed6 /arch/powerpc/kernel/prom_parse.c | |
parent | 9c8e7f5cc965d30006c917ab19221e06fcc5a4f9 (diff) | |
parent | 40a5f7ca07f8e1d77acdba5ae0c11c15cb7520c1 (diff) |
Merge branch 'merge' of git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc
* 'merge' of git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc:
[POWERPC] PReP fixup after irq changes
[POWERPC] SPU fixup after irq changes
[POWERPC] Fix up after irq changes
[POWERPC] Fix iseries/smp.c for irq breakage
[POWERPC] Fix viocons for irq breakage
[POWERPC] Update iseries_defconfig
[POWERPC] Fix fsl_soc build breaks
[POWERPC] Minor fix for bootargs property
[POWERPC] Update MTFSF_L() comment
[POWERPC] Update pSeries defconfig for SATA
[POWERPC] Don't get PCI IRQ from OF for devices with no IRQ
[POWERPC] Fix zImage decompress location
[POWERPC] linux,tce-size property is 32 bits
[POWERPC] Add DTS for MPC8349E-mITX board
[POWERPC] Fix harmless typo
[PPC] Fix some irq breakage with ARCH=ppc
Diffstat (limited to 'arch/powerpc/kernel/prom_parse.c')
-rw-r--r-- | arch/powerpc/kernel/prom_parse.c | 17 |
1 files changed, 11 insertions, 6 deletions
diff --git a/arch/powerpc/kernel/prom_parse.c b/arch/powerpc/kernel/prom_parse.c index 603dff3ad62a..17fcb4842fe5 100644 --- a/arch/powerpc/kernel/prom_parse.c +++ b/arch/powerpc/kernel/prom_parse.c | |||
@@ -914,6 +914,17 @@ int of_irq_map_pci(struct pci_dev *pdev, struct of_irq *out_irq) | |||
914 | u8 pin; | 914 | u8 pin; |
915 | int rc; | 915 | int rc; |
916 | 916 | ||
917 | /* We need to first check if the PCI device has a PCI interrupt at all | ||
918 | * since we have cases where the device-node might expose non-PCI | ||
919 | * interrupts, but the device has no PCI interrupt to it | ||
920 | */ | ||
921 | rc = pci_read_config_byte(pdev, PCI_INTERRUPT_PIN, &pin); | ||
922 | if (rc != 0) | ||
923 | return rc; | ||
924 | /* No pin, exit */ | ||
925 | if (pin == 0) | ||
926 | return -ENODEV; | ||
927 | |||
917 | /* Check if we have a device node, if yes, fallback to standard OF | 928 | /* Check if we have a device node, if yes, fallback to standard OF |
918 | * parsing | 929 | * parsing |
919 | */ | 930 | */ |
@@ -925,12 +936,6 @@ int of_irq_map_pci(struct pci_dev *pdev, struct of_irq *out_irq) | |||
925 | * interrupt spec. we assume #interrupt-cells is 1, which is standard | 936 | * interrupt spec. we assume #interrupt-cells is 1, which is standard |
926 | * for PCI. If you do different, then don't use that routine. | 937 | * for PCI. If you do different, then don't use that routine. |
927 | */ | 938 | */ |
928 | rc = pci_read_config_byte(pdev, PCI_INTERRUPT_PIN, &pin); | ||
929 | if (rc != 0) | ||
930 | return rc; | ||
931 | /* No pin, exit */ | ||
932 | if (pin == 0) | ||
933 | return -ENODEV; | ||
934 | 939 | ||
935 | /* Now we walk up the PCI tree */ | 940 | /* Now we walk up the PCI tree */ |
936 | lspec = pin; | 941 | lspec = pin; |