diff options
author | Eduardo Habkost | 2015-02-08 19:51:16 +0100 |
---|---|---|
committer | Eduardo Habkost | 2015-02-23 19:39:27 +0100 |
commit | e35704ba9ce0cd1e3c401f3bfbf3faf98b0b6885 (patch) | |
tree | 61653fc5b5ee23cda1226ac65fb9abf09cf92e9e /include | |
parent | Merge remote-tracking branch 'remotes/rth/tags/pull-tcg-20150212' into staging (diff) | |
download | qemu-e35704ba9ce0cd1e3c401f3bfbf3faf98b0b6885.tar.gz qemu-e35704ba9ce0cd1e3c401f3bfbf3faf98b0b6885.tar.xz qemu-e35704ba9ce0cd1e3c401f3bfbf3faf98b0b6885.zip |
numa: Move NUMA declarations from sysemu.h to numa.h
Not all sysemu.h users need the NUMA declarations, and keeping them in a
separate file makes it easier to see what are the interfaces provided by
numa.c.
Reviewed-by: Paolo Bonzini <pbonzini@redhat.com>
Acked-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
Diffstat (limited to 'include')
-rw-r--r-- | include/sysemu/numa.h | 28 | ||||
-rw-r--r-- | include/sysemu/sysemu.h | 18 |
2 files changed, 28 insertions, 18 deletions
diff --git a/include/sysemu/numa.h b/include/sysemu/numa.h new file mode 100644 index 0000000000..514914f9a9 --- /dev/null +++ b/include/sysemu/numa.h @@ -0,0 +1,28 @@ +#ifndef SYSEMU_NUMA_H +#define SYSEMU_NUMA_H + +#include <stdint.h> +#include "qemu/bitmap.h" +#include "qemu/option.h" +#include "sysemu/sysemu.h" +#include "sysemu/hostmem.h" + +extern int nb_numa_nodes; /* Number of NUMA nodes */ +extern int max_numa_nodeid; /* Highest specified NUMA node ID, plus one. + * For all nodes, nodeid < max_numa_nodeid + */ + +typedef struct node_info { + uint64_t node_mem; + DECLARE_BITMAP(node_cpu, MAX_CPUMASK_BITS); + struct HostMemoryBackend *node_memdev; + bool present; +} NodeInfo; +extern NodeInfo numa_info[MAX_NODES]; +void set_numa_nodes(void); +void set_numa_modes(void); +void query_numa_node_mem(uint64_t node_mem[]); +extern QemuOptsList qemu_numa_opts; +int numa_init_func(QemuOpts *opts, void *opaque); + +#endif diff --git a/include/sysemu/sysemu.h b/include/sysemu/sysemu.h index 748d0597f0..a72665919b 100644 --- a/include/sysemu/sysemu.h +++ b/include/sysemu/sysemu.h @@ -147,24 +147,6 @@ extern int mem_prealloc; */ #define MAX_CPUMASK_BITS 255 -extern int nb_numa_nodes; /* Number of NUMA nodes */ -extern int max_numa_nodeid; /* Highest specified NUMA node ID, plus one. - * For all nodes, nodeid < max_numa_nodeid - */ - -typedef struct node_info { - uint64_t node_mem; - DECLARE_BITMAP(node_cpu, MAX_CPUMASK_BITS); - struct HostMemoryBackend *node_memdev; - bool present; -} NodeInfo; -extern NodeInfo numa_info[MAX_NODES]; -void set_numa_nodes(void); -void set_numa_modes(void); -void query_numa_node_mem(uint64_t node_mem[]); -extern QemuOptsList qemu_numa_opts; -int numa_init_func(QemuOpts *opts, void *opaque); - #define MAX_OPTION_ROMS 16 typedef struct QEMUOptionRom { const char *name; |