[PATCH] virt-manager: Add firmware preferences for creating a new VM

Cole Robinson crobinso at redhat.com
Wed Jan 26 19:48:53 UTC 2022


On 10/25/21 7:00 PM, Charles Arnold wrote:
> From d30b50139e60afc6e5da1e38f130b27859d31a83 Mon Sep 17 00:00:00 2001
> From: Charles Arnold <carnold at suse.com>
> Date: Mon, 25 Oct 2021 16:16:06 -0600
> Subject: virt-manager: Add firmware preferences for creating a new VM
> 
> Possible values are BIOS (default) and UEFI.
> The firmware used is determined by libvirt unless a specific firmware is
> selected from the Customize dialog.
> 
> See https://bugzilla.redhat.com/show_bug.cgi?id=1997882
> 

Thanks, this seems mostly okay, but I think we need to make this x86
only. Other arches either have no UEFI support, or from virt-manager's
perspective _only_ have UEFI support (aarch64 + arm32 machvirt). So the
internal field and the UI should make it clear this is x86.

The preference UI fields should just be 'System default' and "UEFI".
BIOS value isn't actually handled anywhere in create.py, and we don't
want to provide that option anyways IMO: Eventually when win11 is
supported in osinfo-db, the only option will be UEFI, which means we
would have to error if bios is requested. If we ever start choosing to
set UEFI by default for OS that support both BIOS and UEFI then we can
consider adding a BIOS option here.

In some prep patches I changed virtinst/guest.py to use
os.firmware='efi' if libvirt is new enough, when UEFI is requested. The
attached diff on top of your patch will use that infrastructure, and
give some upfront error reporting if for example it appears uefi is not
available.

If you're cool with those changes I can make them and push, or you can
send a v2

Thanks
Cole
-------------- next part --------------
A non-text attachment was scrubbed...
Name: fixup.patch
Type: text/x-patch
Size: 1624 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/virt-tools-list/attachments/20220126/52f89561/attachment.bin>


More information about the virt-tools-list mailing list