summaryrefslogtreecommitdiffstats
path: root/sys/boot/efi/loader/bootinfo.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/boot/efi/loader/bootinfo.c')
-rw-r--r--sys/boot/efi/loader/bootinfo.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/sys/boot/efi/loader/bootinfo.c b/sys/boot/efi/loader/bootinfo.c
index f3bb9cc..18837f8 100644
--- a/sys/boot/efi/loader/bootinfo.c
+++ b/sys/boot/efi/loader/bootinfo.c
@@ -275,7 +275,7 @@ bi_load_efi_data(struct preloaded_file *kfp)
pages, &addr);
if (EFI_ERROR(status)) {
printf("%s: AllocatePages error %lu\n", __func__,
- (unsigned long)(status & ~EFI_ERROR_MASK));
+ EFI_ERROR_CODE(status));
return (ENOMEM);
}
@@ -291,7 +291,7 @@ bi_load_efi_data(struct preloaded_file *kfp)
status = BS->GetMemoryMap(&sz, mm, &efi_mapkey, &mmsz, &mmver);
if (EFI_ERROR(status)) {
printf("%s: GetMemoryMap error %lu\n", __func__,
- (unsigned long)(status & ~EFI_ERROR_MASK));
+ EFI_ERROR_CODE(status));
return (EINVAL);
}
status = BS->ExitBootServices(IH, efi_mapkey);
@@ -305,8 +305,7 @@ bi_load_efi_data(struct preloaded_file *kfp)
}
BS->FreePages(addr, pages);
}
- printf("ExitBootServices error %lu\n",
- (unsigned long)(status & ~EFI_ERROR_MASK));
+ printf("ExitBootServices error %lu\n", EFI_ERROR_CODE(status));
return (EINVAL);
}
OpenPOWER on IntegriCloud