diff options
author | Yang Zhang <yang.z.zhang@Intel.com> | 2012-06-28 17:51:56 +0100 |
---|---|---|
committer | Yang Zhang <yang.z.zhang@Intel.com> | 2012-06-28 17:51:56 +0100 |
commit | e1e1e98cacd82fa054ac3c6b381d9833236110e0 (patch) | |
tree | 77708e08b3f5c559b3c74d0323d7d33155e00aaa /tools/libxl/libxl_utils.h | |
parent | 928c75ce59fc11c707b8bfd0b99ce0c07ab89926 (diff) | |
download | xen-e1e1e98cacd82fa054ac3c6b381d9833236110e0.tar.gz xen-e1e1e98cacd82fa054ac3c6b381d9833236110e0.tar.bz2 xen-e1e1e98cacd82fa054ac3c6b381d9833236110e0.zip |
libxl: allow setting more than 31 vcpus
In current implementation, it uses integer to record current avail
cpus and this only allows user to specify 31 vcpus. In following
patch, it uses cpumap instead integer which make more sense than
before. Also there is no limit to the max vcpus.
Signed-off-by: Yang Zhang <yang.z.zhang@Intel.com>
Acked-by: Ian Jackson <ian.jackson@eu.citrix.com>
Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
Committed-by: Ian Jackson <ian.jackson@eu.citrix.com>
Diffstat (limited to 'tools/libxl/libxl_utils.h')
-rw-r--r-- | tools/libxl/libxl_utils.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/tools/libxl/libxl_utils.h b/tools/libxl/libxl_utils.h index 7ab0c0915c..a762734c3f 100644 --- a/tools/libxl/libxl_utils.h +++ b/tools/libxl/libxl_utils.h @@ -64,9 +64,11 @@ int libxl_vdev_to_device_disk(libxl_ctx *ctx, uint32_t domid, const char *vdev, libxl_device_disk *disk); int libxl_cpumap_alloc(libxl_ctx *ctx, libxl_cpumap *cpumap, int max_cpus); -int libxl_cpumap_test(libxl_cpumap *cpumap, int cpu); +int libxl_cpumap_test(const libxl_cpumap *cpumap, int cpu); void libxl_cpumap_set(libxl_cpumap *cpumap, int cpu); void libxl_cpumap_reset(libxl_cpumap *cpumap, int cpu); +int libxl_cpumap_count_set(const libxl_cpumap *cpumap); +char *libxl_cpumap_to_hex_string(const libxl_cpumap *cpumap); static inline void libxl_cpumap_set_any(libxl_cpumap *cpumap) { memset(cpumap->map, -1, cpumap->size); |