[U-Boot] [PATCH 1/1] efi_loader: do_bootefi_exec should always return an EFI status code
Heinrich Schuchardt
xypron.glpk at gmx.de
Fri Feb 2 19:05:38 UTC 2018
The return type of do_bootefi_exec() is efi_status_t. So in case
of an error we should always return an EFI status code.
Signed-off-by: Heinrich Schuchardt <xypron.glpk at gmx.de>
---
cmd/bootefi.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/cmd/bootefi.c b/cmd/bootefi.c
index f3ac04bebfb..3df1d3fbd07 100644
--- a/cmd/bootefi.c
+++ b/cmd/bootefi.c
@@ -189,7 +189,7 @@ static efi_status_t do_bootefi_exec(void *efi, void *fdt,
struct efi_loaded_image loaded_image_info = {};
struct efi_object loaded_image_info_obj = {};
struct efi_device_path *memdp = NULL;
- ulong ret;
+ efi_status_t ret;
EFIAPI efi_status_t (*entry)(efi_handle_t image_handle,
struct efi_system_table *st);
@@ -251,7 +251,7 @@ static efi_status_t do_bootefi_exec(void *efi, void *fdt,
/* Load the EFI payload */
entry = efi_load_pe(efi, &loaded_image_info);
if (!entry) {
- ret = -ENOENT;
+ ret = EFI_LOAD_ERROR;
goto exit;
}
--
2.15.1
More information about the U-Boot
mailing list