forked from xt-sys/exectos
Print firmware information, not only secure boot status
This commit is contained in:
parent
71e8bb76de
commit
1b310e46f8
@ -302,6 +302,14 @@ BlStartXtLoader(IN EFI_HANDLE ImageHandle,
|
|||||||
BlEfiPrint(L"ERROR: Failed to initialize serial console\n");
|
BlEfiPrint(L"ERROR: Failed to initialize serial console\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Check SecureBoot status */
|
||||||
|
EfiSecureBoot = BlEfiGetSecureBootStatus();
|
||||||
|
|
||||||
|
/* Print firmware information */
|
||||||
|
BlDbgPrint(L"UEFI v%d.%d (%S 0x%08x), SecureBoot %S\n", EfiSystemTable->Hdr.Revision >> 16,
|
||||||
|
EfiSystemTable->Hdr.Revision & 0xFFFF, EfiSystemTable->FirmwareVendor, EfiSystemTable->FirmwareRevision,
|
||||||
|
EfiSecureBoot == 0 ? L"DISABLED" : EfiSecureBoot > 0 ? L"ENABLED" : L"SETUP");
|
||||||
|
|
||||||
/* Disable watchdog timer */
|
/* Disable watchdog timer */
|
||||||
Status = EfiSystemTable->BootServices->SetWatchdogTimer(0, 0x10000, 0, NULL);
|
Status = EfiSystemTable->BootServices->SetWatchdogTimer(0, 0x10000, 0, NULL);
|
||||||
if(Status != STATUS_EFI_SUCCESS)
|
if(Status != STATUS_EFI_SUCCESS)
|
||||||
@ -310,10 +318,6 @@ BlStartXtLoader(IN EFI_HANDLE ImageHandle,
|
|||||||
BlDbgPrint(L"WARNING: Failed to disable watchdog timer\n");
|
BlDbgPrint(L"WARNING: Failed to disable watchdog timer\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Check SecureBoot status */
|
|
||||||
EfiSecureBoot = BlEfiGetSecureBootStatus();
|
|
||||||
BlDbgPrint(L"SecureBoot status: %S\n", EfiSecureBoot == 0 ? L"DISABLED" : EfiSecureBoot > 0 ? L"ENABLED" : L"SETUP");
|
|
||||||
|
|
||||||
/* Register loader protocol */
|
/* Register loader protocol */
|
||||||
Status = BlRegisterXtLoaderProtocol();
|
Status = BlRegisterXtLoaderProtocol();
|
||||||
if(Status != STATUS_EFI_SUCCESS)
|
if(Status != STATUS_EFI_SUCCESS)
|
||||||
|
Loading…
Reference in New Issue
Block a user