They recently were extracted to a separate function. They don't belong together though. Since -numa formatting is pretty compact, move it to the main function and rename qemuBuildNumaCommandLine to qemuBuildMemoryDeviceCommandLine. --- src/qemu/qemu_command.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c index 8545533..2d0ca97 100644 --- a/src/qemu/qemu_command.c +++ b/src/qemu/qemu_command.c @@ -7182,18 +7182,14 @@ qemuBuildNumaArgStr(virQEMUDriverConfigPtr cfg, static int -qemuBuildNumaCommandLine(virCommandPtr cmd, - virQEMUDriverConfigPtr cfg, - virDomainDefPtr def, - virQEMUCapsPtr qemuCaps, - virBitmapPtr nodeset) +qemuBuildMemoryDeviceCommandLine(virCommandPtr cmd, + virQEMUDriverConfigPtr cfg, + virDomainDefPtr def, + virQEMUCapsPtr qemuCaps, + virBitmapPtr nodeset) { size_t i; - if (virDomainNumaGetNodeCount(def->numa) && - qemuBuildNumaArgStr(cfg, def, cmd, qemuCaps, nodeset) < 0) - return -1; - /* memory hotplug requires NUMA to be enabled - we already checked * that memory devices are present only when NUMA is */ for (i = 0; i < def->nmems; i++) { @@ -9260,7 +9256,11 @@ qemuBuildCommandLine(virConnectPtr conn, if (qemuBuildIOThreadCommandLine(cmd, def, qemuCaps) < 0) goto error; - if (qemuBuildNumaCommandLine(cmd, cfg, def, qemuCaps, nodeset) < 0) + if (virDomainNumaGetNodeCount(def->numa) && + qemuBuildNumaArgStr(cfg, def, cmd, qemuCaps, nodeset) < 0) + goto error; + + if (qemuBuildMemoryDeviceCommandLine(cmd, cfg, def, qemuCaps, nodeset) < 0) goto error; virUUIDFormat(def->uuid, uuid); -- 2.7.3 -- libvir-list mailing list libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list