x86_64: don't need set default res if only have one root bus
authorYinghai Lu <yhlu.kernel.send@gmail.com>
Fri, 11 Apr 2008 22:14:52 +0000 (15:14 -0700)
committerIngo Molnar <mingo@elte.hu>
Sat, 26 Apr 2008 21:41:04 +0000 (23:41 +0200)
if there's only one root bus there's no need to split resources.

This patch fixes the issue described at:

  http://lkml.org/lkml/2008/4/10/304

Reported-and-bisected-by: Rafael J. Wysocki <rjw@sisk.pl>
Tested-by: Rafael J. Wysocki <rjw@sisk.pl>
Signed-off-by: Yinghai Lu <yhlu.kernel@gmail.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
arch/x86/pci/k8-bus_64.c

index 84b2030fc2f098fb23677c9d9d138f1e4abaa9f7..4e64c58e17a0d2c9699772f99c13453c3c876dfb 100644 (file)
@@ -69,7 +69,8 @@ void set_pci_bus_resources_arch_default(struct pci_bus *b)
        int j;
        struct pci_root_info *info;
 
-       if (!pci_root_num)
+       /* if only one root bus, don't need to anything */
+       if (pci_root_num < 2)
                return;
 
        for (i = 0; i < pci_root_num; i++) {