This series was split out from my memory hotplug series that is not quite ready yet. The aim of this series is to refactor the code that creates commandline for the memory-backend-* qemu object so that it can be later reused for hotplug via monitor. Additionally this series also fixes a bug in NUMA memory initialisation where qemu doesn't support a combination of old and new approach. Version 2 fixes bugs found by first round of review. Patch 4/13 is new in this series. Please see individual patches for changes. (If the change line isn't present the patch was not reviewed) Peter Krempa (13): conf: numatune: Extract code for requesting memory nodeset from formatting test: utils: Add helpers for automatic numbering of test cases util: json: make value object creator universal by supporting adding util: bitmap: Add option to allocate bitmap without reporting error util: json: Add functions to convert JSON arrays from/to virBitmaps util: json: add helper to iterate JSON object key=value pairs qemu: command: Add helper to format -object strings from JSON representation qemu: Extract code to setup memory backing objects qemu: command: Shuffle around formating of alias for memory backend objs qemu: command: Unify values for boolean values when formating memory backends qemu: command: Switch to bytes when formatting size for memory backends qemu: command: Refactor NUMA backend object formatting to use JSON objs qemu: command: Don't combine old and modern NUMA node creation src/conf/numatune_conf.c | 33 +- src/conf/numatune_conf.h | 5 + src/libvirt_private.syms | 7 + src/qemu/qemu_command.c | 547 +++++++++++++++------ src/qemu/qemu_command.h | 4 + src/util/virbitmap.c | 42 +- src/util/virbitmap.h | 1 + src/util/virjson.c | 222 ++++++++- src/util/virjson.h | 17 + tests/Makefile.am | 13 +- tests/qemucommandutiltest.c | 118 +++++ .../qemuxml2argv-hugepages-pages.args | 20 +- .../qemuxml2argv-hugepages-pages2.args | 8 +- .../qemuxml2argv-hugepages-pages3.args | 7 +- .../qemuxml2argv-hugepages-shared.args | 20 +- .../qemuxml2argv-numatune-memnode-no-memory.args | 6 +- .../qemuxml2argv-numatune-memnode.args | 8 +- tests/testutils.c | 52 ++ tests/testutils.h | 3 + 19 files changed, 912 insertions(+), 221 deletions(-) create mode 100644 tests/qemucommandutiltest.c -- 2.2.2 -- libvir-list mailing list libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list