x86: fix memoryless node oops during boot
authorYinghai Lu <yhlu.kernel@gmail.com>
Mon, 25 Feb 2008 07:23:09 +0000 (23:23 -0800)
committerIngo Molnar <mingo@elte.hu>
Wed, 26 Mar 2008 21:23:40 +0000 (22:23 +0100)
fix oops during boot reported in this thread:

  http://lkml.org/lkml/2008/2/6/65

enable booting on memoryless nodes.

Reported-by: Kamalesh Babulal <kamalesh@linux.vnet.ibm.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
arch/x86/kernel/setup_64.c

index 7637dc91c79bebac16365bbcff3b480c408584ef..f4f7ecfb898c7628eb220143dd7ad54b60a4ccbd 100644 (file)
@@ -801,7 +801,7 @@ static void __cpuinit srat_detect_node(void)
        /* Don't do the funky fallback heuristics the AMD version employs
           for now. */
        node = apicid_to_node[apicid];
-       if (node == NUMA_NO_NODE)
+       if (node == NUMA_NO_NODE || !node_online(node))
                node = first_node(node_online_map);
        numa_set_node(cpu, node);