qemu-upstream has "-machine" option, "-M" is an alias. qemu-kvm-rhel6 only has "-M" option.
So add "-M .." parameters when "-machine" or "-M" exists. Signed-off-by: Amos Kong <[email protected]> --- 0 files changed, 0 insertions(+), 0 deletions(-) diff --git a/client/virt/kvm_vm.py b/client/virt/kvm_vm.py index 4dd5f70..87a506a 100644 --- a/client/virt/kvm_vm.py +++ b/client/virt/kvm_vm.py @@ -603,7 +603,10 @@ class VM(virt_vm.BaseVM): return "" def add_machine_type(help, machine_type): - return " -M %s" % machine_type + if has_option(help, "machine") or has_option(help, "M"): + return " -M %s" % machine_type + else: + return "" def add_usb(help, usb_id, usb_type, multifunction=False, masterbus=None, firstport=None, freq=None): _______________________________________________ Autotest mailing list [email protected] http://test.kernel.org/cgi-bin/mailman/listinfo/autotest
