ppc4xx: Setup pci interrupt line registers on sequoia boards
PATCH 1/1 ppc4xx: Setup pci interrupt line registers on sequoia boards
ppc4xx: Setup pci interrupt line registers on sequoia boards
This patch writes the correct interrupt numbers into the pci interrupt line register on sequoia boards when PCI PNP (CONFIG_PCI_PNP) is enabled. Even U-Boot does not use interrupts some OS rely on this.
Signed-off-by Matthias Fuchs <[email protected]>
---
commit 99c549cae6cbecd07fe860d2e652653ad23869f1
tree 851ae01b5a35f9c6913473a86006b4c85c969438
parent 3c908811a5e7098d476976eed54a4f8b0e80edc7
author Matthias Fuchs <[email protected]> Thu, 21 Jun 2007 15:32:46 +0200 committer Matthias Fuchs <[email protected]> Thu, 21 Jun 2007 15:32:46 +0200
board/amcc/sequoia/sequoia.c | 17 +++++++++++++++-- 1 files changed, 15 insertions(+), 2 deletions(-)
board/amcc/sequoia/sequoia.c +15 -2
@@ -414,6 +414,18 @@ int testdram(void) }#endif +#if defined(CONFIG_PCI ) && defined(CFG_PCI_PRE_INIT ) +#ifdef CONFIG_PCI_PNP +/* +* Assign interrupts to PCI devices. Some OSs rely on this. +* All PCI interrupt lines are connected to ext. interrupt 2 (=67) +*/ +void sequoia_pci_fixup_irq (struct pci_controller *hose,pci_dev_t dev) +{ +pci_hose_write_config_byte (hose, dev,PCI_INTERRUPT_LINE ,67 ); +} +#endif +/************************************************************************* * pci_pre_init *
@@ -426,7 +438,6 @@ int testdram(void)* certain pre-initialization actions. * ************************************************************************/ -#if defined(CONFIG_PCI ) && defined(CFG_PCI_PRE_INIT )int pci_pre_init (struct pci_controller *hose) {unsigned long addr;
@@ -477,7 +488,9 @@ int pci_pre_init(struct pci_controller * addr = (addr & ~plb1_acr_rdp_mask) | plb1_acr_rdp_4deep; addr = (addr & ~plb1_acr_wrp_mask) | plb1_acr_wrp_2deep;mtdcr (plb1_acr, addr); - +#ifdef CONFIG_PCI_PNP + hose->fixup_irq = sequoia_pci_fixup_irq; +#endif return 1; }#endif /* defined(CONFIG_PCI) && defined(CFG_PCI_PRE_INIT) */