Check ExitBootServices() status code
All checks were successful
ci/woodpecker/push/build Pipeline was successful
All checks were successful
ci/woodpecker/push/build Pipeline was successful
This commit is contained in:
parent
fb60625abc
commit
0461d975e0
@ -113,7 +113,12 @@ BlEnablePaging(IN PLIST_ENTRY MemoryMappings,
|
||||
|
||||
/* Exit EFI Boot Services */
|
||||
BlDbgPrint(L"Exiting EFI boot services\n");
|
||||
EfiSystemTable->BootServices->ExitBootServices(EfiImageHandle, MemoryMap->MapKey);
|
||||
Status = EfiSystemTable->BootServices->ExitBootServices(EfiImageHandle, MemoryMap->MapKey);
|
||||
if(Status != STATUS_EFI_SUCCESS)
|
||||
{
|
||||
BlDbgPrint(L"Failed to exit boot services (Status code: %lx)\n", Status);
|
||||
return STATUS_EFI_ABORTED;
|
||||
}
|
||||
|
||||
/* No runtime services should touch boot services code, so get rid of it all at this point */
|
||||
EfiSystemTable->RuntimeServices->SetVirtualAddressMap(MemoryMap->MapSize, MemoryMap->DescriptorSize,
|
||||
|
@ -199,7 +199,12 @@ BlEnablePaging(IN PLIST_ENTRY MemoryMappings,
|
||||
|
||||
/* Exit EFI Boot Services */
|
||||
BlDbgPrint(L"Exiting EFI boot services\n");
|
||||
EfiSystemTable->BootServices->ExitBootServices(EfiImageHandle, MemoryMap->MapKey);
|
||||
Status = EfiSystemTable->BootServices->ExitBootServices(EfiImageHandle, MemoryMap->MapKey);
|
||||
if(Status != STATUS_EFI_SUCCESS)
|
||||
{
|
||||
BlDbgPrint(L"Failed to exit boot services (Status code: %lx)\n", Status);
|
||||
return STATUS_EFI_ABORTED;
|
||||
}
|
||||
|
||||
/* No runtime services should touch boot services code, so get rid of it all at this point */
|
||||
EfiSystemTable->RuntimeServices->SetVirtualAddressMap(MemoryMap->MapSize, MemoryMap->DescriptorSize,
|
||||
|
@ -238,7 +238,11 @@ XtpBootSequence(IN PEFI_FILE_HANDLE BootDir,
|
||||
|
||||
/* Enable paging */
|
||||
EfiSystemTable->BootServices->HandleProtocol(EfiImageHandle, &LoadedImageGuid, (PVOID*)&ImageProtocol);
|
||||
XtLdrProtocol->EnablePaging(&MemoryMappings, VirtualAddress, ImageProtocol, &XtPageMap);
|
||||
Status = XtLdrProtocol->EnablePaging(&MemoryMappings, VirtualAddress, ImageProtocol, &XtPageMap);
|
||||
if(Status != STATUS_EFI_SUCCESS)
|
||||
{
|
||||
return Status;
|
||||
}
|
||||
|
||||
/* Call XTOS kernel */
|
||||
XtLdrProtocol->DbgPrint(L"Booting the XTOS kernel\n");
|
||||
|
Loading…
Reference in New Issue
Block a user