]> git.karo-electronics.de Git - linux-beck.git/commit
x86-64, NUMA: Prepare numa_emulation() for moving NUMA emulation into a separate...
authorTejun Heo <tj@kernel.org>
Tue, 22 Feb 2011 10:10:08 +0000 (11:10 +0100)
committerTejun Heo <tj@kernel.org>
Tue, 22 Feb 2011 10:10:08 +0000 (11:10 +0100)
commitfbe99959d1db85222829a64d869dcab704ac7ec8
treed9a73b523cf21fbe51f572cdcfe36225a7964e83
parent69efcc6d90d234a3a076afb2c635c1609536faa4
x86-64, NUMA: Prepare numa_emulation() for moving NUMA emulation into a separate file

Update numa_emulation() such that, it

- takes @numa_meminfo and @numa_dist_cnt instead of directly
  referencing the global variables.

- copies the distance table by iterating each distance with
  node_distance() instead of memcpy'ing the distance table.

- tests emu_cmdline to determine whether emulation is requested and
  fills emu_nid_to_phys[] with identity mapping if emulation is not
  used.  This allows the caller to call numa_emulation()
  unconditionally and makes return value unncessary.

- defines dummy version if CONFIG_NUMA_EMU is disabled.

This patch doesn't introduce any behavior change.

Signed-off-by: Tejun Heo <tj@kernel.org>
Cc: Yinghai Lu <yinghai@kernel.org>
Cc: Ingo Molnar <mingo@redhat.com>
arch/x86/mm/numa_64.c