Cannot start a UEFI vm when pci memory mapped exceed 32GB

Bug #2043985 reported by Sergio Rabellino
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
New
Undecided
peter.zw

Bug Description

Launching a libvirt vm with a UEFI boot with PCI cards (e.g. PCI passthrough of GPU cards) results in a black screen and no boot sequence at all.
This is due to limitations in UEFI Bios boot code (OVMF) which limits to 32GB the max memory mapping, so using GPUs that owns more memory than 32GB (summing up all the GPUs attached) the UEFI boot will fail to start at all.

Following the documentation, latest OVMF has a special flag that can be used to ask to UEFI to allow more than 32GB mem alloc to PCI memory map ( https://edk2.groups.io/g/discuss/topic/59340711 ) which can be specified into the domain XML file for the VM.

The attached patches are a workaround to allow using UEFI with GPUs (tested on a Rocky 9.x with 4 nVIDIA V100 SXM2 cards, with a total of 128GB of pci memory map). The patch tries to sum-up from the host the needed memory aperture and tries to understand if the current OVMF release has the needed options (this should be enhanced further).

HTH

Tags: libvirt gpu uefi
Revision history for this message
Sergio Rabellino (rabser) wrote :
peter.zw (zzwfree)
Changed in nova:
assignee: nobody → peter.zw (zzwfree)
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.