[libvirt] [PATCH v2 0/3] New vCPU hotplug prequel

John Ferlan jferlan at redhat.com
Thu Aug 4 13:37:27 UTC 2016



On 08/04/2016 06:40 AM, Peter Krempa wrote:
> Few of the patches needed more significant changes.
> 
> Peter Krempa (3):
>   internal: Introduce macro for stealing pointers
>   qemu: monitor: Return structures from qemuMonitorGetCPUInfo
>   qemu: monitor: Return struct from qemuMonitor(Text|Json)QueryCPUs
> 
>  src/internal.h               | 12 +++++++
>  src/qemu/qemu_domain.c       | 25 ++++++--------
>  src/qemu/qemu_monitor.c      | 70 ++++++++++++++++++++++++++++++++++++----
>  src/qemu/qemu_monitor.h      | 19 ++++++++++-
>  src/qemu/qemu_monitor_json.c | 77 +++++++++++++++++++++++---------------------
>  src/qemu/qemu_monitor_json.h |  3 +-
>  src/qemu/qemu_monitor_text.c | 39 +++++++++++-----------
>  src/qemu/qemu_monitor_text.h |  3 +-
>  tests/qemumonitorjsontest.c  | 39 +++++++++++++++-------
>  9 files changed, 194 insertions(+), 93 deletions(-)
> 

ACK series with the following caveats

NIT: There's only a 1 line gap between qemuMonitorCPUInfoFree and
qemuMonitorQueryCpusFree instead of the normal 2...

In patch 2, once info allocation is successful, both error paths will
steal info and neither can return -1.

By patch 3 things are adjusted such that -1 can be returned from the
JSON/Text query functions since the -2 status is added to denote
'non-fatal'.

IOW: For 1 patch we have a situation where something is different.

So if you're fine with the 1 patch oddity - fine... Or you could merge
the two together in order to avoid the extra work to add -2 to patch 2.

John




More information about the libvir-list mailing list