提交 cfe24c1a 编写于 作者: J Jiri Denemark

qemu: Move -enable-kvm and friends earlier in the command line

上级 a98541bf
......@@ -5885,6 +5885,15 @@ qemuBuildCommandLine(virConnectPtr conn,
if (qemuBuildMachineArgStr(cmd, def, qemuCaps) < 0)
goto error;
if (disableKQEMU)
virCommandAddArg(cmd, "-no-kqemu");
else if (enableKQEMU)
virCommandAddArgList(cmd, "-enable-kqemu", "-kernel-kqemu", NULL);
if (disableKVM)
virCommandAddArg(cmd, "-no-kvm");
if (enableKVM)
virCommandAddArg(cmd, "-enable-kvm");
if (qemuBuildCpuArgStr(driver, def, emulator, qemuCaps,
hostarch, &cpu, &hasHwVirt, !!migrateFrom) < 0)
goto error;
......@@ -5898,15 +5907,6 @@ qemuBuildCommandLine(virConnectPtr conn,
virCommandAddArg(cmd, "-enable-nesting");
}
if (disableKQEMU)
virCommandAddArg(cmd, "-no-kqemu");
else if (enableKQEMU)
virCommandAddArgList(cmd, "-enable-kqemu", "-kernel-kqemu", NULL);
if (disableKVM)
virCommandAddArg(cmd, "-no-kvm");
if (enableKVM)
virCommandAddArg(cmd, "-enable-kvm");
if (def->os.loader) {
virCommandAddArg(cmd, "-bios");
virCommandAddArg(cmd, def->os.loader);
......
LC_ALL=C PATH=/bin HOME=/home/test USER=test LOGNAME=test /usr/bin/qemu -S -M pc \
-cpu host,-kvmclock -enable-kvm -m 214 -smp 6 \
-enable-kvm -cpu host,-kvmclock -m 214 -smp 6 \
-nographic -monitor unix:/tmp/test-monitor,server,nowait -no-acpi -boot n -usb -net \
none -serial none -parallel none
LC_ALL=C PATH=/bin HOME=/home/test USER=test LOGNAME=test /usr/bin/qemu -S -M pc \
-cpu core2duo,-kvmclock -enable-kvm -m 214 -smp 6 \
-enable-kvm -cpu core2duo,-kvmclock -m 214 -smp 6 \
-nographic -monitor unix:/tmp/test-monitor,server,nowait -no-acpi -boot n -usb -net \
none -serial none -parallel none
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册