Skip to contentSkip to conversation

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

PATCH In review Yinghai Lu 3 participants 3 messages Apr 11, 2008 – Apr 13, 2008

Subsystems (2)
lore
Share & tools
lore

Yinghai Lu

author
#0 lore raw

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

only one root bus, don't need to split that root resources.

arch/x86/pci/k8-bus_64.c +2 -1
index 7ed7f51..c433982 100644
@@ -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++) {
Tested-by on v1 1/1
#1 lore raw
Quoted 1 line · Yinghai Lu

only one root bus, don't need to split that root resources.

This patch fixes the issue described at
http://lkml.org/lkml/2008/4/10/304 and in the following thread for me.

Quoted 1 line
Quoted 7 lines
arch/x86/pci/k8-bus_64.c +0 -0
index 7ed7f51..c433982 100644

arch/x86/pci/k8-bus_64.c void set_pci_bus_resources_arch_default(struct pci_bus *b) · line 76

Quoted 9 lines
arch/x86/pci/k8-bus_64.c +2 -1
@@ -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++) {

Thanks,
Rafael