From: Yunping Zheng <[email protected]> this patch add qemu '-no-kvm', '-no-shutdown' option support, use disable_hardware_virtual is yes/no to decide whether or not disable hardware virtualization when starting the guest. use enable_no_shutdown yes/no to decide whether or not disable qemu no shutdown this patch also add command prefix support. you can use some command prefix(like:taskset,valgring and so on)in test.like: #valgrind qemu-kvm
Signed-off-by: Yunping Zheng <[email protected]> --- client/virt/kvm_vm.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/client/virt/kvm_vm.py b/client/virt/kvm_vm.py index 566924d..e330366 100644 --- a/client/virt/kvm_vm.py +++ b/client/virt/kvm_vm.py @@ -949,6 +949,10 @@ class VM(virt_vm.BaseVM): qemu_cmd += "LD_LIBRARY_PATH=%s " % library_path if params.get("qemu_audio_drv"): qemu_cmd += "QEMU_AUDIO_DRV=%s " % params.get("qemu_audio_drv") + #Add command prefix for qemu-kvm. like taskset valgrind and so on. + if params.get("qemu_command_prefix"): + qemu_command_prefix = params.get("qemu_command_prefix") + qemu_cmd += "%s " % qemu_command_prefix # Add numa memory cmd to pin guest memory to numa node if params.get("numa_node"): numa_node = int(params.get("numa_node")) @@ -1375,6 +1379,14 @@ class VM(virt_vm.BaseVM): and params.get("enable-kvm", "yes") == "yes"): qemu_cmd += " -enable-kvm" + if has_option(help, "no-kvm") and params.get("disable_hardware_virtual", + "no") == "yes": + qemu_cmd += " -no-kvm " + + if has_option(help, "no-shutdown") and params.get("enable_no_shutdown", + "no") == "yes": + qemu_cmd += " -no-shutdown " + if params.get("enable_sga") == "yes": qemu_cmd += add_sga(help) -- 1.7.11.4 _______________________________________________ Autotest-kernel mailing list [email protected] https://www.redhat.com/mailman/listinfo/autotest-kernel
