Skip to contentSkip to conversation

x86_64 - UV fix for memory-only blades

PATCH In review Jack Steiner 2 participants 3 messages May 15, 2009 – May 20, 2009

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 x86_64 - UV fix for memory-only blades

Fix an endcase in handling UV blades that have memory but no cpus. The calculation of the highest blade number failed to handle these blades if they appear last in the configuration.

---
 arch/x86/kernel/apic/x2apic_uv_x.c |    1 +
 1 file changed, 1 insertion(+)
arch/x86/kernel/apic/x2apic_uv_x.c +1 -0
Index: linux/arch/x86/kernel/apic/x2apic_uv_x.c
===================================================================
@@ -632,6 +632,7 @@ void __init uv_system_init(void)
 		pnode = (paddr >> m_val) & pnode_mask;
 		blade = boot_pnode_to_blade(pnode);
 		uv_node_to_blade[nid] = blade;
+		max_pnode = max(pnode, max_pnode);
 	}
 
 	map_gru_high(max_pnode);
#1 lore raw
Quoted 16 lines · Jack Steiner

Fix an endcase in handling UV blades that have memory but no cpus. The calculation of the highest blade number failed to handle these blades if they appear last in the configuration.

---
 arch/x86/kernel/apic/x2apic_uv_x.c |    1 +
 1 file changed, 1 insertion(+)

Index: linux/arch/x86/kernel/apic/x2apic_uv_x.c
===================================================================

arch/x86/kernel/apic/x2apic_uv_x.c void __init uv_system_init(void) · line 638

Quoted 7 lines
arch/x86/kernel/apic/x2apic_uv_x.c +1 -0
@@ -632,6 +632,7 @@ void __init uv_system_init(void)
 		pnode = (paddr >> m_val) & pnode_mask;
 		blade = boot_pnode_to_blade(pnode);
 		uv_node_to_blade[nid] = blade;
+		max_pnode = max(pnode, max_pnode);
 	}
 
 	map_gru_high(max_pnode);

node_possible_map should already include nodes with memory and without memory already.

maybe you could skip max_pnode calculating in the loop.

YH

#2 lore raw
Quoted 23 lines · Yinghai Lu
Quoted 22 lines · Jack Steiner

Fix an endcase in handling UV blades that have memory but no cpus. The calculation of the highest blade number failed to handle these blades if they appear last in the configuration.

---
 arch/x86/kernel/apic/x2apic_uv_x.c |    1 +
 1 file changed, 1 insertion(+)

Index: linux/arch/x86/kernel/apic/x2apic_uv_x.c
===================================================================

arch/x86/kernel/apic/x2apic_uv_x.c +1 -0
@@ -632,6 +632,7 @@ void __init uv_system_init(void)
 		pnode = (paddr >> m_val) & pnode_mask;
 		blade = boot_pnode_to_blade(pnode);
 		uv_node_to_blade[nid] = blade;
+		max_pnode = max(pnode, max_pnode);
 	}
 
Quoted 5 lines

arch/x86/kernel/apic/x2apic_uv_x.c void __init uv_system_init(void) · line 638

Quoted 1 line
arch/x86/kernel/apic/x2apic_uv_x.c +0 -0
 	map_gru_high(max_pnode);

node_possible_map should already include nodes with memory and without memory already.

maybe you could skip max_pnode calculating in the loop.

Terms related to nodes are grossly overloaded.

"pnode" is only loosely related to a node. It is a physical node number that is a hardware-thing. For example, it is possible to have a 1 node system with a max_pnode of 128.

pnodes are used only in the UV infrastructure - they have no generic meaning nor would they apply to any other platform.

--- jack