Add $GUEST_TWEAKS variable to allow for guest_os specific tweaks

This commit is contained in:
Martin Wimpress 2020-03-21 15:22:01 +00:00
parent 061abfe9b5
commit 6e6b5ae702
No known key found for this signature in database
GPG Key ID: 61DF940515E06DA3
1 changed files with 3 additions and 1 deletions

View File

@ -91,6 +91,7 @@ function vm_boot() {
local VMDIR=$(dirname ${disk_img})
local BIOS=""
local CPU="-cpu host,kvm=on"
local GUEST_TWEAKS=""
local VIDEO_DRV=""
local GL="on"
local VIRGL="on"
@ -125,6 +126,7 @@ function vm_boot() {
;;
windows)
CPU="${CPU},hv_time"
GUEST_TWEAKS="-no-hpet"
VIDEO_DRV="qxl"
;;
*)
@ -265,7 +267,7 @@ function vm_boot() {
# Boot the iso image
${QEMU} -name ${VMNAME},process=${VMNAME} \
${BIOS} \
${BIOS} ${GUEST_TWEAKS} \
-drive id=disk,file=${disk_img},format=qcow2,if=virtio,aio=native,cache.direct=on \
${ISO_BOOT} ${ISO_DRIVER} \
-enable-kvm \