Browse Source

x86_64: don't need set default res if only have one root bus

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>
Yinghai Lu 17 năm trước cách đây
mục cha
commit
4cf1946374
1 tập tin đã thay đổi với 2 bổ sung1 xóa
  1. 2 1
      arch/x86/pci/k8-bus_64.c

+ 2 - 1
arch/x86/pci/k8-bus_64.c

@@ -69,7 +69,8 @@ void set_pci_bus_resources_arch_default(struct pci_bus *b)
 	int j;
 	int j;
 	struct pci_root_info *info;
 	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;
 		return;
 
 
 	for (i = 0; i < pci_root_num; i++) {
 	for (i = 0; i < pci_root_num; i++) {