• T
    x86-64, NUMA: Wrap node ID during emulation · 775ee85d
    Tejun Heo 提交于
    Both emulation layout functions - split_nodes[_size]_interleave() -
    didn't wrap emulated nid while laying out the fake nodes and tried to
    avoid interating over the specified number of nodes, which is fragile.
    
    Now that the emulation code generates numa_meminfo, the node memblks
    don't need to be consecutive and emulated node IDs can simply wrap.
    This makes the code more robust and is necessary for updates to better
    handle the cases where the physical nodes are interleaved.
    Signed-off-by: NTejun Heo <tj@kernel.org>
    Cc: Yinghai Lu <yinghai@kernel.org>
    Cc: Brian Gerst <brgerst@gmail.com>
    Cc: Cyrill Gorcunov <gorcunov@gmail.com>
    Cc: Shaohui Zheng <shaohui.zheng@intel.com>
    Cc: David Rientjes <rientjes@google.com>
    Cc: Ingo Molnar <mingo@elte.hu>
    Cc: H. Peter Anvin <hpa@linux.intel.com>
    775ee85d
numa_64.c 27.8 KB