From: Yinghai Lu Date: Wed, 22 Apr 2009 21:19:27 +0000 (-0700) Subject: x86: check boundary in setup_node_bootmem() X-Git-Tag: firefly_0821_release~14320^2~1 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=4c31e92b97b6d7e7b19ee5e54a22571ffdebb305;p=firefly-linux-kernel-4.4.55.git x86: check boundary in setup_node_bootmem() Commit dc09855 ("x86/uv: fix init of memory-less nodes") causes a two sockets system (where node-1 doesn't have RAM installed) to crash. That commit makes node_possible include cpu nodes that do not have memory. So check boundary in setup_node_bootmem(). [ Impact: fix boot crash on RAM-less NUMA node system ] Signed-off-by: Yinghai Lu Cc: Jack Steiner LKML-Reference: <49EF89DF.9090404@kernel.org> Signed-off-by: Ingo Molnar --- diff --git a/arch/x86/mm/numa_64.c b/arch/x86/mm/numa_64.c index d73aaa892371..2d05a12029dc 100644 --- a/arch/x86/mm/numa_64.c +++ b/arch/x86/mm/numa_64.c @@ -188,6 +188,9 @@ void __init setup_node_bootmem(int nodeid, unsigned long start, const int pgdat_size = roundup(sizeof(pg_data_t), PAGE_SIZE); int nid; + if (!end) + return; + start = roundup(start, ZONE_ALIGN); printk(KERN_INFO "Bootmem setup node %d %016lx-%016lx\n", nodeid,