summaryrefslogtreecommitdiff
path: root/testusb.sh
diff options
context:
space:
mode:
Diffstat (limited to 'testusb.sh')
-rwxr-xr-xtestusb.sh9
1 files changed, 8 insertions, 1 deletions
diff --git a/testusb.sh b/testusb.sh
index bed799b..2cca502 100755
--- a/testusb.sh
+++ b/testusb.sh
@@ -3,4 +3,11 @@
# SPDX-License-Identifier: GPL-3.0-or-later
# Test the live USB in QEMU, you need to run this script as root
-qemu-system-x86_64 -enable-kvm -cpu host -m 2G -drive "file=$1,format=raw"
+if [ "$1" == uefi ]; then
+ bios=(-bios /usr/share/edk2-ovmf/x64/OVMF.fd)
+ shift
+else
+ bios=()
+fi
+
+qemu-system-x86_64 -enable-kvm -cpu host -m 2G "${bios[@]}" -drive "file=$1,format=raw"