mirror of
				https://github.com/oSoWoSo/DistroHopper.git
				synced 2024-08-14 22:46:53 +00:00 
			
		
		
		
	Set virgl=off when booted using EFI
OVMF booting appears to not be compatible with virgl
This commit is contained in:
		
							parent
							
								
									c664baaf08
								
							
						
					
					
						commit
						3b5fdcb6ea
					
				
					 1 changed files with 5 additions and 5 deletions
				
			
		
							
								
								
									
										10
									
								
								quickemu.sh
									
										
									
									
									
								
							
							
						
						
									
										10
									
								
								quickemu.sh
									
										
									
									
									
								
							|  | @ -33,16 +33,15 @@ function vm_boot() { | ||||||
|   local VMNAME=$(basename ${VM} .conf) |   local VMNAME=$(basename ${VM} .conf) | ||||||
|   local BIOS="" |   local BIOS="" | ||||||
|   local GL="on" |   local GL="on" | ||||||
|  |   local VIRGL="on" | ||||||
|   local UI="sdl" |   local UI="sdl" | ||||||
|   if [ ${ENABLE_EFI} -eq 1 ]; then |   if [ ${ENABLE_EFI} -eq 1 ]; then | ||||||
|     if [ "${ENGINE}" == "virgil" ] && [ -e /snap/qemu-virgil/current/usr/share/qemu/edk2-x86_64-code.fd ] ; then |     if [ "${ENGINE}" == "virgil" ] && [ -e /snap/qemu-virgil/current/usr/share/qemu/edk2-x86_64-code.fd ] ; then | ||||||
|       BIOS="-drive if=pflash,format=raw,readonly,file=/snap/qemu-virgil/current/usr/share/qemu/edk2-x86_64-code.fd" |       BIOS="-drive if=pflash,format=raw,readonly,file=/snap/qemu-virgil/current/usr/share/qemu/edk2-x86_64-code.fd" | ||||||
|       GL="off" |       VIRGL="off" | ||||||
|       UI="gtk" |  | ||||||
|     elif [ -e /usr/share/qemu/OVMF.fd ]; then |     elif [ -e /usr/share/qemu/OVMF.fd ]; then | ||||||
|       BIOS="-drive if=pflash,format=raw,readonly,file=/usr/share/qemu/OVMF.fd" |       BIOS="-drive if=pflash,format=raw,readonly,file=/usr/share/qemu/OVMF.fd" | ||||||
|       GL="off" |       VIRGL="off" | ||||||
|       UI="gtk" |  | ||||||
|     else |     else | ||||||
|       echo " - EFI:      Booting requested but no EFI firmware found." |       echo " - EFI:      Booting requested but no EFI firmware found." | ||||||
|       echo "             Booting from Legacy BIOS." |       echo "             Booting from Legacy BIOS." | ||||||
|  | @ -94,6 +93,7 @@ function vm_boot() { | ||||||
|   fi |   fi | ||||||
|   echo " - UI:       ${UI}" |   echo " - UI:       ${UI}" | ||||||
|   echo " - GL:       ${GL}" |   echo " - GL:       ${GL}" | ||||||
|  |   echo " - VIRGL:    ${VIRGL}" | ||||||
| 
 | 
 | ||||||
|   # TODO: Detect Wayland here and "do the right thing". |   # TODO: Detect Wayland here and "do the right thing". | ||||||
|   # Determine the most suitable 16:9 resolution of for VM based |   # Determine the most suitable 16:9 resolution of for VM based | ||||||
|  | @ -153,7 +153,7 @@ function vm_boot() { | ||||||
|     -object rng-random,id=rng0,filename=/dev/urandom \ |     -object rng-random,id=rng0,filename=/dev/urandom \ | ||||||
|     -device virtio-rng-pci,rng=rng0 \ |     -device virtio-rng-pci,rng=rng0 \ | ||||||
|     -device qemu-xhci \ |     -device qemu-xhci \ | ||||||
|     -device virtio-vga,virgl=on,xres=${xres},yres=${yres} \ |     -device virtio-vga,virgl=${VIRGL},xres=${xres},yres=${yres} \ | ||||||
|     ${display} \ |     ${display} \ | ||||||
|     "$@" 2>/dev/null |     "$@" 2>/dev/null | ||||||
| } | } | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue