summaryrefslogtreecommitdiff
path: root/tools/testing/memblock/scripts
diff options
context:
space:
mode:
authorRebecca Mckeever <remckee0@gmail.com>2022-09-13 08:21:09 +0300
committerMike Rapoport <rppt@linux.ibm.com>2022-09-18 10:30:20 +0300
commitb338bde5a3a9c4ccf6c83e0a20c8de3ad281ef02 (patch)
tree5137fd304e37120ab120b2c1129d021f1cda8afc /tools/testing/memblock/scripts
parent42c3ba86581896be8dd7fb88ed075b600fd57fa1 (diff)
downloadlinux-b338bde5a3a9c4ccf6c83e0a20c8de3ad281ef02.tar.xz
memblock tests: add simulation of physical memory with multiple NUMA nodes
Add function setup_numa_memblock() for setting up a memory layout with multiple NUMA nodes in a previously allocated dummy physical memory. This function can be used in place of setup_memblock() in tests that need to simulate a NUMA system. setup_numa_memblock(): - allows for setting up a memory layout by specifying the fraction of MEM_SIZE in each node Set CONFIG_NODES_SHIFT to 4 when building with NUMA=1 to allow for up to 16 NUMA nodes. Reviewed-by: David Hildenbrand <david@redhat.com> Signed-off-by: Rebecca Mckeever <remckee0@gmail.com> Signed-off-by: Mike Rapoport <rppt@linux.ibm.com> Link: https://lore.kernel.org/r/4566d816a85f009268d4858d1ef06c7571a960f9.1663046060.git.remckee0@gmail.com
Diffstat (limited to 'tools/testing/memblock/scripts')
-rw-r--r--tools/testing/memblock/scripts/Makefile.include2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/testing/memblock/scripts/Makefile.include b/tools/testing/memblock/scripts/Makefile.include
index aa6d82d56a23..998281723590 100644
--- a/tools/testing/memblock/scripts/Makefile.include
+++ b/tools/testing/memblock/scripts/Makefile.include
@@ -3,7 +3,7 @@
# Simulate CONFIG_NUMA=y
ifeq ($(NUMA), 1)
- CFLAGS += -D CONFIG_NUMA
+ CFLAGS += -D CONFIG_NUMA -D CONFIG_NODES_SHIFT=4
endif
# Use 32 bit physical addresses.