Re: [PATCHv3 3/6] tests: add qemumonitorjson tests for query-cpus-fast

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On 04/04/2018 10:45 AM, Viktor Mihajlovski wrote:
> Extended the json monitor test program with support for query-cpus-fast
> and added a sample file set for x86 data obtained using the it.
> Also extend the test program to recognize the halted property.

This last sentence involves code that probably should be separated into
its own patch since it's unrelated to the new data. If it's moved this
patch into one previously, then this patch/adjustment "proves" nothing
changes (which is good).

I can do that for you so you don't have to post another series.  I would
make you the author and add your S-o-b... Of course I need you to say OK
for that too!

The rest of this shows what I'd extract...

> 
> Signed-off-by: Viktor Mihajlovski <mihajlov@xxxxxxxxxxxxxxxxxx>
> ---
>  .../qemumonitorjson-cpuinfo-ppc64-hotplug-4.data   |   8 ++
>  ...emumonitorjson-cpuinfo-x86-basic-pluggable.data |   5 +
>  ...qemumonitorjson-cpuinfo-x86-full-fast-cpus.json | 126 +++++++++++++++++++++
>  ...umonitorjson-cpuinfo-x86-full-fast-hotplug.json | 115 +++++++++++++++++++
>  .../qemumonitorjson-cpuinfo-x86-full-fast.data     | 109 ++++++++++++++++++
>  .../qemumonitorjson-cpuinfo-x86-node-full.data     |   2 +
>  tests/qemumonitorjsontest.c                        | 121 +++++++++++++++-----
>  tests/qemumonitortestutils.c                       |   7 ++
>  tests/qemumonitortestutils.h                       |   1 +
>  9 files changed, 468 insertions(+), 26 deletions(-)
>  create mode 100644 tests/qemumonitorjsondata/qemumonitorjson-cpuinfo-x86-full-fast-cpus.json
>  create mode 100644 tests/qemumonitorjsondata/qemumonitorjson-cpuinfo-x86-full-fast-hotplug.json
>  create mode 100644 tests/qemumonitorjsondata/qemumonitorjson-cpuinfo-x86-full-fast.data
> 
> diff --git a/tests/qemumonitorjsondata/qemumonitorjson-cpuinfo-ppc64-hotplug-4.data b/tests/qemumonitorjsondata/qemumonitorjson-cpuinfo-ppc64-hotplug-4.data
> index 7c90889..5f6b865 100644
> --- a/tests/qemumonitorjsondata/qemumonitorjson-cpuinfo-ppc64-hotplug-4.data
> +++ b/tests/qemumonitorjsondata/qemumonitorjson-cpuinfo-ppc64-hotplug-4.data
> @@ -52,41 +52,49 @@
>      alias='vcpu0'
>      qom_path='/machine/peripheral/vcpu0'
>      topology: core='8' vcpus='8'
> +    halted
>  [vcpu libvirt-id='9']
>      online=yes
>      hotpluggable=yes
>      thread-id='23171'
>      query-cpus-id='17'
> +    halted
>  [vcpu libvirt-id='10']
>      online=yes
>      hotpluggable=yes
>      thread-id='23172'
>      query-cpus-id='18'
> +    halted
>  [vcpu libvirt-id='11']
>      online=yes
>      hotpluggable=yes
>      thread-id='23173'
>      query-cpus-id='19'
> +    halted
>  [vcpu libvirt-id='12']
>      online=yes
>      hotpluggable=yes
>      thread-id='23174'
>      query-cpus-id='20'
> +    halted
>  [vcpu libvirt-id='13']
>      online=yes
>      hotpluggable=yes
>      thread-id='23175'
>      query-cpus-id='21'
> +    halted
>  [vcpu libvirt-id='14']
>      online=yes
>      hotpluggable=yes
>      thread-id='23176'
>      query-cpus-id='22'
> +    halted
>  [vcpu libvirt-id='15']
>      online=yes
>      hotpluggable=yes
>      thread-id='23177'
>      query-cpus-id='23'
> +    halted
>  [vcpu libvirt-id='16']
>      online=yes
>      hotpluggable=yes> diff --git
a/tests/qemumonitorjsondata/qemumonitorjson-cpuinfo-x86-basic-pluggable.data
b/tests/qemumonitorjsondata/qemumonitorjson-cpuinfo-x86-basic-pluggable.data
> index 93cefb9..9a1788d 100644
> --- a/tests/qemumonitorjsondata/qemumonitorjson-cpuinfo-x86-basic-pluggable.data
> +++ b/tests/qemumonitorjsondata/qemumonitorjson-cpuinfo-x86-basic-pluggable.data
> @@ -7,6 +7,7 @@
>      type='qemu64-x86_64-cpu'
>      qom_path='/machine/unattached/device[0]'
>      topology: socket='0' core='0' thread='0' vcpus='1'
> +    halted
>  [vcpu libvirt-id='1']
>      online=yes
>      hotpluggable=no
> @@ -16,6 +17,7 @@
>      type='qemu64-x86_64-cpu'
>      qom_path='/machine/unattached/device[2]'
>      topology: socket='0' core='0' thread='1' vcpus='1'
> +    halted
>  [vcpu libvirt-id='2']
>      online=yes
>      hotpluggable=no
> @@ -25,6 +27,7 @@
>      type='qemu64-x86_64-cpu'
>      qom_path='/machine/unattached/device[3]'
>      topology: socket='0' core='1' thread='0' vcpus='1'
> +    halted
>  [vcpu libvirt-id='3']
>      online=yes
>      hotpluggable=no
> @@ -34,6 +37,7 @@
>      type='qemu64-x86_64-cpu'
>      qom_path='/machine/unattached/device[4]'
>      topology: socket='0' core='1' thread='1' vcpus='1'
> +    halted
>  [vcpu libvirt-id='4']
>      online=yes
>      hotpluggable=no
> @@ -43,6 +47,7 @@
>      type='qemu64-x86_64-cpu'
>      qom_path='/machine/unattached/device[5]'
>      topology: socket='1' core='0' thread='0' vcpus='1'
> +    halted
>  [vcpu libvirt-id='5']
>      online=no
>      hotpluggable=yes

[...]

> diff --git a/tests/qemumonitorjsondata/qemumonitorjson-cpuinfo-x86-node-full.data b/tests/qemumonitorjsondata/qemumonitorjson-cpuinfo-x86-node-full.data
> index 070ea08..0f7dbf1 100644
> --- a/tests/qemumonitorjsondata/qemumonitorjson-cpuinfo-x86-node-full.data
> +++ b/tests/qemumonitorjsondata/qemumonitorjson-cpuinfo-x86-node-full.data
> @@ -7,6 +7,7 @@
>      type='Broadwell-x86_64-cpu'
>      qom_path='/machine/unattached/device[0]'
>      topology: socket='0' core='0' thread='0' node='0' vcpus='1'
> +    halted
>  [vcpu libvirt-id='1']
>      online=yes
>      hotpluggable=no
> @@ -16,6 +17,7 @@
>      type='Broadwell-x86_64-cpu'
>      qom_path='/machine/unattached/device[2]'
>      topology: socket='0' core='0' thread='1' node='1' vcpus='1'
> +    halted
>  [vcpu libvirt-id='2']
>      online=no
>      hotpluggable=yes
> diff --git a/tests/qemumonitorjsontest.c b/tests/qemumonitorjsontest.c
> index 0add50a..5daa2c9 100644
> --- a/tests/qemumonitorjsontest.c
> +++ b/tests/qemumonitorjsontest.c

[...]

>  
> @@ -2669,6 +2715,9 @@ testQemuMonitorCPUInfoFormat(qemuMonitorCPUInfoPtr vcpus,
>              virBufferAddLit(&buf, "\n");
>          }
>  
> +        if (vcpu->halted)
> +            virBufferAddLit(&buf, "halted\n");
> +
>          virBufferAdjustIndent(&buf, -4);
>      }
>  
> @@ -2681,12 +2730,14 @@ testQemuMonitorCPUInfo(const void *opaque)

[...]

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list



[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux