diff options
author | Yinghai Lu <yhlu.kernel.send@gmail.com> | 2008-04-19 04:30:16 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-07-08 05:28:46 -0400 |
commit | dbb6152e6f72df367f8a955586c5e6282a7255e5 (patch) | |
tree | c9b477aea9fc1cad80274dc69dffa0b394ad7fce /arch/x86/pci/acpi.c | |
parent | b755de8dfdfef97effaa91379ffafcb81f4d62a1 (diff) |
x86: don't call pxm_to_node again
also make bus_numa work even if ACPI_NUMA is not defined.
don't call pxm_to_node again, and use node directly.
Signed-off-by: Yinghai Lu <yhlu.kernel@gmail.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'arch/x86/pci/acpi.c')
-rw-r--r-- | arch/x86/pci/acpi.c | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/arch/x86/pci/acpi.c b/arch/x86/pci/acpi.c index ea8685f89bc3..28d17a5cfb8d 100644 --- a/arch/x86/pci/acpi.c +++ b/arch/x86/pci/acpi.c | |||
@@ -171,11 +171,11 @@ struct pci_bus * __devinit pci_acpi_scan_root(struct acpi_device *device, int do | |||
171 | if (node != -1) | 171 | if (node != -1) |
172 | set_mp_bus_to_node(busnum, node); | 172 | set_mp_bus_to_node(busnum, node); |
173 | else | 173 | else |
174 | #endif | ||
174 | node = get_mp_bus_to_node(busnum); | 175 | node = get_mp_bus_to_node(busnum); |
175 | 176 | ||
176 | if (node != -1 && !node_online(node)) | 177 | if (node != -1 && !node_online(node)) |
177 | node = -1; | 178 | node = -1; |
178 | #endif | ||
179 | 179 | ||
180 | /* Allocate per-root-bus (not per bus) arch-specific data. | 180 | /* Allocate per-root-bus (not per bus) arch-specific data. |
181 | * TODO: leak; this memory is never freed. | 181 | * TODO: leak; this memory is never freed. |
@@ -207,14 +207,16 @@ struct pci_bus * __devinit pci_acpi_scan_root(struct acpi_device *device, int do | |||
207 | if (!bus) | 207 | if (!bus) |
208 | kfree(sd); | 208 | kfree(sd); |
209 | 209 | ||
210 | if (bus && node != -1) { | ||
210 | #ifdef CONFIG_ACPI_NUMA | 211 | #ifdef CONFIG_ACPI_NUMA |
211 | if (bus) { | 212 | if (pxm >= 0) |
212 | if (pxm >= 0) { | ||
213 | printk(KERN_DEBUG "bus %02x -> pxm %d -> node %d\n", | 213 | printk(KERN_DEBUG "bus %02x -> pxm %d -> node %d\n", |
214 | busnum, pxm, pxm_to_node(pxm)); | 214 | busnum, pxm, node); |
215 | } | 215 | #else |
216 | } | 216 | printk(KERN_DEBUG "bus %02x -> node %d\n", |
217 | busnum, node); | ||
217 | #endif | 218 | #endif |
219 | } | ||
218 | 220 | ||
219 | if (bus && (pci_probe & PCI_USE__CRS)) | 221 | if (bus && (pci_probe & PCI_USE__CRS)) |
220 | get_current_resources(device, busnum, domain, bus); | 222 | get_current_resources(device, busnum, domain, bus); |