qemu uses this if 'maxcpus' is not present. Do the same in the parsing code. --- src/qemu/qemu_parse_command.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/qemu/qemu_parse_command.c b/src/qemu/qemu_parse_command.c index 7ab3dcf..ed92caa 100644 --- a/src/qemu/qemu_parse_command.c +++ b/src/qemu/qemu_parse_command.c @@ -1713,8 +1713,14 @@ qemuParseCommandLineSmp(virDomainDefPtr dom, goto syntax; } - if (maxcpus == 0) - maxcpus = vcpus; + if (maxcpus == 0) { + if (cores) { + if (virDomainDefGetVcpusTopology(dom, &maxcpus) < 0) + goto error; + } else { + maxcpus = vcpus; + } + } if (maxcpus == 0) goto syntax; -- 2.10.2 -- libvir-list mailing list libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list