mirror of
https://xff.cz/git/u-boot/
synced 2025-09-05 10:42:10 +02:00
efi_loader: fix BootOrder variable measurement handling
UEFI specification does not require that BootOrder is defined. In current implementation, boot variable measurement fails and returns EFI_NOT_FOUND if BootOrder is not defined. This commit correcly handles this case, skip the boot variable measurement if BootOrder is not defined. Signed-off-by: Masahisa Kojima <masahisa.kojima@linaro.org> Acked-by: Ilias Apalodimas <ilias.apalodimas@linaro.org> Reviewed-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
This commit is contained in:
committed by
Heinrich Schuchardt
parent
6354913def
commit
c9c1cdbda3
@@ -1452,8 +1452,8 @@ static efi_status_t tcg2_measure_boot_variable(struct udevice *dev)
|
|||||||
boot_order = efi_get_var(var_name, &efi_global_variable_guid,
|
boot_order = efi_get_var(var_name, &efi_global_variable_guid,
|
||||||
&var_data_size);
|
&var_data_size);
|
||||||
if (!boot_order) {
|
if (!boot_order) {
|
||||||
ret = EFI_NOT_FOUND;
|
/* If "BootOrder" is not defined, skip the boot variable measurement */
|
||||||
goto error;
|
return EFI_SUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
ret = tcg2_measure_variable(dev, 1, EV_EFI_VARIABLE_BOOT2, var_name,
|
ret = tcg2_measure_variable(dev, 1, EV_EFI_VARIABLE_BOOT2, var_name,
|
||||||
|
Reference in New Issue
Block a user