aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/platforms/chrp
diff options
context:
space:
mode:
authorKumar Gala <galak@kernel.crashing.org>2007-06-27 02:17:57 -0400
committerKumar Gala <galak@kernel.crashing.org>2007-06-29 02:58:37 -0400
commit5516b540e98de6f7474a4e7149470ad6a0bbc54a (patch)
tree9eb57336d892eb8c0e76584285030868df82f626 /arch/powerpc/platforms/chrp
parent6a506238b33efd93e60c1585d654b37e292183de (diff)
[POWERPC] Use global_number in ppc32 pci_controller
Make the pci_controller struct use global_number for the PHB domain number instead of index to match what ppc64 does and reuse its pci_domain_nr code. Introduced a pci-common.c to handle shared code between ppc32 & ppc64. Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
Diffstat (limited to 'arch/powerpc/platforms/chrp')
-rw-r--r--arch/powerpc/platforms/chrp/pci.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/powerpc/platforms/chrp/pci.c b/arch/powerpc/platforms/chrp/pci.c
index d32fedc991d3..d8408632b1a9 100644
--- a/arch/powerpc/platforms/chrp/pci.c
+++ b/arch/powerpc/platforms/chrp/pci.c
@@ -99,7 +99,7 @@ int rtas_read_config(struct pci_bus *bus, unsigned int devfn, int offset,
99 struct pci_controller *hose = bus->sysdata; 99 struct pci_controller *hose = bus->sysdata;
100 unsigned long addr = (offset & 0xff) | ((devfn & 0xff) << 8) 100 unsigned long addr = (offset & 0xff) | ((devfn & 0xff) << 8)
101 | (((bus->number - hose->first_busno) & 0xff) << 16) 101 | (((bus->number - hose->first_busno) & 0xff) << 16)
102 | (hose->index << 24); 102 | (hose->global_number << 24);
103 int ret = -1; 103 int ret = -1;
104 int rval; 104 int rval;
105 105
@@ -114,7 +114,7 @@ int rtas_write_config(struct pci_bus *bus, unsigned int devfn, int offset,
114 struct pci_controller *hose = bus->sysdata; 114 struct pci_controller *hose = bus->sysdata;
115 unsigned long addr = (offset & 0xff) | ((devfn & 0xff) << 8) 115 unsigned long addr = (offset & 0xff) | ((devfn & 0xff) << 8)
116 | (((bus->number - hose->first_busno) & 0xff) << 16) 116 | (((bus->number - hose->first_busno) & 0xff) << 16)
117 | (hose->index << 24); 117 | (hose->global_number << 24);
118 int rval; 118 int rval;
119 119
120 rval = rtas_call(rtas_token("write-pci-config"), 3, 1, NULL, 120 rval = rtas_call(rtas_token("write-pci-config"), 3, 1, NULL,