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

Re: [libvirt] [PATCH 1/6] cputune: new tests for testing cputune xml



On Sun, 27 Feb 2011 22:39:16 +0800, Osier Yang <jyang redhat com> wrote:
> ---
>  tests/qemuxml2argvdata/qemuxml2argv-cputune.args |    4 ++
>  tests/qemuxml2argvdata/qemuxml2argv-cputune.xml  |   33 ++++++++++++++++++++++
>  tests/qemuxml2argvtest.c                         |    1 +
>  tests/qemuxml2xmltest.c                          |    1 +
>  4 files changed, 39 insertions(+), 0 deletions(-)
>  create mode 100644 tests/qemuxml2argvdata/qemuxml2argv-cputune.args
>  create mode 100644 tests/qemuxml2argvdata/qemuxml2argv-cputune.xml
> 
> diff --git a/tests/qemuxml2argvdata/qemuxml2argv-cputune.args b/tests/qemuxml2argvdata/qemuxml2argv-cputune.args
> new file mode 100644
> index 0000000..c41cec0
> --- /dev/null
> +++ b/tests/qemuxml2argvdata/qemuxml2argv-cputune.args
> @@ -0,0 +1,4 @@
> +LC_ALL=C PATH=/bin HOME=/home/test USER=test LOGNAME=test /usr/bin/qemu -S -M \
> +pc -m 214 -smp 2 -name QEMUGuest1 -nographic \
> +-monitor unix:/tmp/test-monitor,server,nowait -no-acpi -boot c \
> +-hda /dev/HostVG/QEMUGuest1 -net none -serial none -parallel none -usb
> diff --git a/tests/qemuxml2argvdata/qemuxml2argv-cputune.xml b/tests/qemuxml2argvdata/qemuxml2argv-cputune.xml
> new file mode 100644
> index 0000000..76173ec
> --- /dev/null
> +++ b/tests/qemuxml2argvdata/qemuxml2argv-cputune.xml
> @@ -0,0 +1,33 @@
> +<domain type='qemu'>
> +  <name>QEMUGuest1</name>
> +  <uuid>c7a5fdbd-edaf-9455-926a-d65c16db1809</uuid>
> +  <memory>219136</memory>
> +  <currentMemory>219136</currentMemory>
> +  <vcpu>2</vcpu>
> +  <cputune>
> +    <shares>2048</shares>
> +    <vcpupin vcpu='0' cpuset='0'/>
> +    <vcpupin vcpu='1' cpuset='1'/>
> +  </cputune>
> +  <os>
> +    <type arch='i686' machine='pc'>hvm</type>
> +    <boot dev='hd'/>
> +  </os>
> +  <cpu>
> +    <topology sockets='2' cores='1' threads='1'/>
> +  </cpu>
> +  <clock offset='utc'/>
> +  <on_poweroff>destroy</on_poweroff>
> +  <on_reboot>restart</on_reboot>
> +  <on_crash>destroy</on_crash>
> +  <devices>
> +    <emulator>/usr/bin/qemu</emulator>
> +    <disk type='block' device='disk'>
> +      <source dev='/dev/HostVG/QEMUGuest1'/>
> +      <target dev='hda' bus='ide'/>
> +      <address type='drive' controller='0' bus='0' unit='0'/>
> +    </disk>
> +    <controller type='ide' index='0'/>
> +    <memballoon model='virtio'/>
> +  </devices>
> +</domain>
> diff --git a/tests/qemuxml2argvtest.c b/tests/qemuxml2argvtest.c
> index d2864ef..ffa93bf 100644
> --- a/tests/qemuxml2argvtest.c
> +++ b/tests/qemuxml2argvtest.c
> @@ -490,6 +490,7 @@ mymain(int argc, char **argv)
> 
>      DO_TEST("memtune", false, QEMU_CAPS_NAME);
>      DO_TEST("blkiotune", false, QEMU_CAPS_NAME);
> +    DO_TEST("cputune", false, QEMU_CAPS_NAME);
> 
>      free(driver.stateDir);
>      virCapabilitiesFree(driver.caps);
> diff --git a/tests/qemuxml2xmltest.c b/tests/qemuxml2xmltest.c
> index 67e721b..3ee94fc 100644
> --- a/tests/qemuxml2xmltest.c
> +++ b/tests/qemuxml2xmltest.c
> @@ -184,6 +184,7 @@ mymain(int argc, char **argv)
>      DO_TEST("encrypted-disk");
>      DO_TEST("memtune");
>      DO_TEST("blkiotune");
> +    DO_TEST("cputune");
> 
>      DO_TEST("smp");
> 

Reviewed-by: "Nikunj A. Dadhania" <nikunj linux vnet ibm com>

Regards
Nikunj


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