Re: [PATCH] do not clean dummy variable in kexec path

From: Matthew Garrett
Date: Mon Aug 05 2019 - 13:09:58 EST


On Mon, Aug 5, 2019 at 1:36 AM Dave Young <dyoung@xxxxxxxxxx> wrote:
>
> kexec reboot fails randomly in UEFI based kvm guest. The firmware
> just reset while calling efi_delete_dummy_variable(); Unfortunately
> I don't know how to debug the firmware, it is also possible a potential
> problem on real hardware as well although nobody reproduced it.
>
> The intention of efi_delete_dummy_variable is to trigger garbage collection
> when entering virtual mode. But SetVirtualAddressMap can only run once
> for each physical reboot, thus kexec_enter_virtual_mode is not necessarily
> a good place to clean dummy object.

I agree that this isn't necessarily the best place to do this in the
kexec case, but given we control the firmware, figuring out what's
actually breaking seems like a good plan.