From e75e2a14d5c13ad38dcf72b69922dee2dafbb0d0 Mon Sep 17 00:00:00 2001 From: Bharata B Rao Date: Mon, 29 Jun 2015 13:50:27 +0530 Subject: numa: API to lookup NUMA node by address Introduce an API numa_get_node(ram_addr_t addr, Error **errp) that returns the NUMA node to which the given address belongs to. This API works uniformly for both boot time as well as hotplugged memory. This API is needed by sPAPR PowerPC to support ibm,dynamic-reconfiguration-memory device tree node which is needed for memory hotplug. Signed-off-by: Bharata B Rao Reviewed-by: David Gibson Tested-by: Igor Mammedov Signed-off-by: Eduardo Habkost --- include/sysemu/numa.h | 1 + 1 file changed, 1 insertion(+) (limited to 'include/sysemu/numa.h') diff --git a/include/sysemu/numa.h b/include/sysemu/numa.h index 7176364062..a6392bc50f 100644 --- a/include/sysemu/numa.h +++ b/include/sysemu/numa.h @@ -31,5 +31,6 @@ void query_numa_node_mem(uint64_t node_mem[]); extern QemuOptsList qemu_numa_opts; void numa_set_mem_node_id(ram_addr_t addr, uint64_t size, uint32_t node); void numa_unset_mem_node_id(ram_addr_t addr, uint64_t size, uint32_t node); +uint32_t numa_get_node(ram_addr_t addr, Error **errp); #endif -- cgit v1.2.3