Skip to contentSkip to conversation

numa: check NUMA nodes with memdev specified

PATCH New Li Zhang 1 participant 1 message Feb 18, 2022

lore
Share & tools
lore

Li Zhang

author
#0 lore raw

PATCH v2 1/1 numa: check NUMA nodes with memdev specified

If there is no memdev in numa configuration, it always reports the error as the following:

total memory for NUMA nodes (0x0) should equal RAM size (0x100000000)

This error is confusing, and the total memory is the memory of NUMA nodes with memdev specified actually. The memory size of a node without memdev specified is always 0. So it's better to remind users to check the memory of the NUMA nodes with memdev specified.

---
 hw/core/numa.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
hw/core/numa.c +2 -1
index 1aa05dcf42..7e1dbab0d5 100644
@@ -688,7 +688,8 @@ void numa_complete_configuration(MachineState *ms)
             numa_total += numa_info[i].node_mem;
         }
         if (numa_total != ms->ram_size) {
-            error_report("total memory for NUMA nodes (0x%" PRIx64 ")"
+            error_report("total memory for NUMA nodes specified"
+                         " with memdev backend memory (0x%" PRIx64 ")"
                          " should equal RAM size (0x" RAM_ADDR_FMT ")",
                          numa_total, ms->ram_size);
             exit(1);
Signature · 1 line
2.31.1