Linux MIPS Architecture development
 help / color / mirror / Atom feed
* [PATCH 1/4] MIPS: ath79: allow to specify bus number in PCI IRQ maps
@ 2013-02-03 10:58 Gabor Juhos
  2013-02-03 10:58 ` [PATCH 2/4] MIPS: pci-ar724x: use dynamically allocated PCI controller structure Gabor Juhos
                   ` (3 more replies)
  0 siblings, 4 replies; 9+ messages in thread
From: Gabor Juhos @ 2013-02-03 10:58 UTC (permalink / raw)
  To: Ralf Baechle; +Cc: linux-mips, John Crispin, Gabor Juhos

This is needed for multiple PCI bus support.

Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
---
 arch/mips/ath79/pci.c |    4 +++-
 arch/mips/ath79/pci.h |    1 +
 2 files changed, 4 insertions(+), 1 deletion(-)

diff --git a/arch/mips/ath79/pci.c b/arch/mips/ath79/pci.c
index c94bcec..d90e071 100644
--- a/arch/mips/ath79/pci.c
+++ b/arch/mips/ath79/pci.c
@@ -75,7 +75,9 @@ int __init pcibios_map_irq(const struct pci_dev *dev, uint8_t slot, uint8_t pin)
 		const struct ath79_pci_irq *entry;
 
 		entry = &ath79_pci_irq_map[i];
-		if (entry->slot == slot && entry->pin == pin) {
+		if (entry->bus == dev->bus->number &&
+		    entry->slot == slot &&
+		    entry->pin == pin) {
 			irq = entry->irq;
 			break;
 		}
diff --git a/arch/mips/ath79/pci.h b/arch/mips/ath79/pci.h
index 51c6625..1d00a38 100644
--- a/arch/mips/ath79/pci.h
+++ b/arch/mips/ath79/pci.h
@@ -14,6 +14,7 @@
 #define _ATH79_PCI_H
 
 struct ath79_pci_irq {
+	int	bus;
 	u8	slot;
 	u8	pin;
 	int	irq;
-- 
1.7.10

^ permalink raw reply related	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2013-02-04 13:14 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-02-03 10:58 [PATCH 1/4] MIPS: ath79: allow to specify bus number in PCI IRQ maps Gabor Juhos
2013-02-03 10:58 ` [PATCH 2/4] MIPS: pci-ar724x: use dynamically allocated PCI controller structure Gabor Juhos
2013-02-03 10:59 ` [PATCH 3/4] MIPS: pci-ar724x: remove static PCI IO/MEM resources Gabor Juhos
2013-02-03 11:18   ` Sergei Shtylyov
2013-02-03 12:31     ` Gabor Juhos
2013-02-04 12:13       ` Sergei Shtylyov
2013-02-04 13:14         ` Gabor Juhos
2013-02-03 11:00 ` [PATCH 4/4] MIPS: pci-ar724x: use per-controller IRQ base Gabor Juhos
2013-02-03 15:52 ` [PATCH 5/4] MIPS: pci-ar724x: setup command register of the PCI controller Gabor Juhos

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox