Initialize XTLDR configuration list and check if EFI LoadedImage protocol opened successfully
This commit is contained in:
parent
16a2565ad9
commit
32042ef643
@ -564,7 +564,7 @@ BlpUpdateConfiguration(IN PLIST_ENTRY NewConfig)
|
||||
/* Make sure config entry does not exist yet */
|
||||
if(BlGetConfigValue(ConfigEntry->Name) == NULL)
|
||||
{
|
||||
/* Remove new config entry from input list and put it into global config list */
|
||||
/* Put new config entry into global config list */
|
||||
RtlInsertTailList(BlpConfig, &ConfigEntry->Flink);
|
||||
}
|
||||
|
||||
|
@ -143,22 +143,28 @@ BlpInitializeEfiBootLoader()
|
||||
/* Print XTLDR version */
|
||||
BlConsolePrint(L"XTLDR boot loader v%s\n", XTOS_VERSION);
|
||||
|
||||
/* Initialize XTLDR configuration list */
|
||||
RtlInitializeListHead(BlpConfig);
|
||||
|
||||
/* Check if debug is enabled */
|
||||
if(DEBUG)
|
||||
{
|
||||
/* Attempt to open EFI LoadedImage protocol */
|
||||
Status = BlOpenXtProtocol((PVOID *)&LoadedImage, &LipGuid);
|
||||
|
||||
/* Print useful debug information */
|
||||
BlConsolePrint(L"\n---------- BOOTLOADER DEBUG ----------\n"
|
||||
L"Pointer Size : %d\n"
|
||||
L"Image Base Address: 0x%lx\n"
|
||||
L"Image Base Size : 0x%lx\n"
|
||||
L"Image Revision : 0x%lx\n"
|
||||
L"--------------------------------------\n",
|
||||
sizeof(PVOID),
|
||||
LoadedImage->ImageBase,
|
||||
LoadedImage->ImageSize,
|
||||
LoadedImage->Revision);
|
||||
BlSleepExecution(5000);
|
||||
if(Status == STATUS_EFI_SUCCESS)
|
||||
{
|
||||
/* Protocol opened successfully, print useful debug information */
|
||||
BlConsolePrint(L"\n---------- BOOTLOADER DEBUG ----------\n"
|
||||
L"Pointer Size : %d\n"
|
||||
L"Image Base Address: 0x%lx\n"
|
||||
L"Image Base Size : 0x%lx\n"
|
||||
L"Image Revision : 0x%lx\n"
|
||||
L"--------------------------------------\n",
|
||||
sizeof(PVOID),
|
||||
LoadedImage->ImageBase,
|
||||
LoadedImage->ImageSize,
|
||||
LoadedImage->Revision);
|
||||
BlSleepExecution(3000);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -10,7 +10,7 @@
|
||||
|
||||
|
||||
/* XT Boot Loader configuration list */
|
||||
PLIST_ENTRY BlpConfig = NULL;
|
||||
PLIST_ENTRY BlpConfig;
|
||||
|
||||
/* XT Boot Loader loaded configuration */
|
||||
LIST_ENTRY BlpConfigSections;
|
||||
|
Loading…
Reference in New Issue
Block a user