From: Prerna Saxena Date: Tue, 4 Nov 2014 17:32:15 +0000 (+0530) Subject: Test: Add a testcase for PowerPC compat mode cpu specification. X-Git-Tag: CVE-2014-8135~216 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=12c381114ce362e49cadb730b5faabbc150a8878;p=thirdparty%2Flibvirt.git Test: Add a testcase for PowerPC compat mode cpu specification. This introduces a testcase for PowerPC compat mode cpu specification. Signed-off-by: Prerna Saxena Reviewed-by: Michal Privoznik --- diff --git a/tests/qemuxml2argvdata/qemuxml2argv-pseries-cpu-compat.args b/tests/qemuxml2argvdata/qemuxml2argv-pseries-cpu-compat.args new file mode 100644 index 0000000000..64df406e1d --- /dev/null +++ b/tests/qemuxml2argvdata/qemuxml2argv-pseries-cpu-compat.args @@ -0,0 +1,8 @@ +LC_ALL=C PATH=/bin HOME=/home/test USER=test LOGNAME=test \ +QEMU_AUDIO_DRV=none /usr/bin/qemu-system-ppc64 -S -M pseries \ +-cpu host,compat=power7 \ +-m 214 -smp 4 -nographic -nodefconfig -nodefaults \ +-chardev socket,id=charmonitor,path=/tmp/test-monitor,server,nowait \ +-mon chardev=charmonitor,id=monitor,mode=readline -no-acpi -boot c -usb \ +-chardev pty,id=charserial0 \ +-device spapr-vty,chardev=charserial0,reg=0x30000000 diff --git a/tests/qemuxml2argvdata/qemuxml2argv-pseries-cpu-compat.xml b/tests/qemuxml2argvdata/qemuxml2argv-pseries-cpu-compat.xml new file mode 100644 index 0000000000..e34a8ad8dd --- /dev/null +++ b/tests/qemuxml2argvdata/qemuxml2argv-pseries-cpu-compat.xml @@ -0,0 +1,20 @@ + + QEMUGuest1 + 219100 + 219100 + 4 + + hvm + + + power7 + + + + /usr/bin/qemu-system-ppc64 + +
+ + + + diff --git a/tests/qemuxml2argvtest.c b/tests/qemuxml2argvtest.c index 63e61bd274..fe58a247a4 100644 --- a/tests/qemuxml2argvtest.c +++ b/tests/qemuxml2argvtest.c @@ -1310,6 +1310,8 @@ mymain(void) QEMU_CAPS_DEVICE, QEMU_CAPS_NODEFCONFIG); DO_TEST("pseries-cpu-exact", QEMU_CAPS_CHARDEV, QEMU_CAPS_DEVICE, QEMU_CAPS_NODEFCONFIG); + DO_TEST("pseries-cpu-compat", QEMU_CAPS_KVM, QEMU_CAPS_CPU_HOST, + QEMU_CAPS_CHARDEV, QEMU_CAPS_DEVICE, QEMU_CAPS_NODEFCONFIG); DO_TEST("disk-ide-drive-split", QEMU_CAPS_DRIVE, QEMU_CAPS_DEVICE, QEMU_CAPS_NODEFCONFIG, QEMU_CAPS_IDE_CD);