mirror of
https://git.proxmox.com/git/efi-boot-shim
synced 2025-06-07 17:43:43 +00:00
Explain the logic in secure_mode() better.
I was getting confused reading it, and I wrote it, so clearly it needs more commentry. Signed-off-by: Peter Jones <pjones@redhat.com>
This commit is contained in:
parent
c36d88cb16
commit
86173dba42
6
shim.c
6
shim.c
@ -499,6 +499,12 @@ static BOOLEAN secure_mode (void)
|
|||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* If we /do/ have "SecureBoot", but /don't/ have "SetupMode",
|
||||||
|
* then the implementation is bad, but we assume that secure boot is
|
||||||
|
* enabled according to the status of "SecureBoot". If we have both
|
||||||
|
* of them, then "SetupMode" may tell us additional data, and we need
|
||||||
|
* to consider it.
|
||||||
|
*/
|
||||||
status = get_variable(L"SetupMode", &Data, &len, global_var);
|
status = get_variable(L"SetupMode", &Data, &len, global_var);
|
||||||
if (status != EFI_SUCCESS)
|
if (status != EFI_SUCCESS)
|
||||||
return TRUE;
|
return TRUE;
|
||||||
|
Loading…
Reference in New Issue
Block a user