Skip to content

Commit 4902aad

Browse files
committed
Minor reordering of function calls near entry point
1 parent d8989e1 commit 4902aad

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

src/csmwrap.c

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -98,13 +98,15 @@ EFI_STATUS efi_main(EFI_HANDLE ImageHandle, EFI_SYSTEM_TABLE *SystemTable)
9898
gBS = SystemTable->BootServices;
9999
gRT = SystemTable->RuntimeServices;
100100

101+
gBS->SetWatchdogTimer(0, 0, 0, NULL);
102+
103+
printf("%s", banner);
104+
101105
if (gRT->GetTime(&gTimeAtBoot, NULL) != EFI_SUCCESS) {
102106
printf("Failed to query current time\n");
103107
return -1;
104108
}
105109

106-
printf("%s", banner);
107-
108110
EFI_GUID loaded_image_guid = EFI_LOADED_IMAGE_PROTOCOL_GUID;
109111
EFI_LOADED_IMAGE_PROTOCOL *loaded_image = NULL;
110112
if (gBS->HandleProtocol(ImageHandle, &loaded_image_guid, (void **)&loaded_image) != EFI_SUCCESS) {
@@ -139,7 +141,6 @@ EFI_STATUS efi_main(EFI_HANDLE ImageHandle, EFI_SYSTEM_TABLE *SystemTable)
139141
}
140142

141143
gBS->RaiseTPL(TPL_NOTIFY);
142-
gBS->SetWatchdogTimer(0, 0, 0, NULL);
143144

144145
if (unlock_bios_region()) {
145146
printf("Unable to unlock BIOS region\n");

0 commit comments

Comments
 (0)