aboutsummaryrefslogtreecommitdiff
path: root/cmd
diff options
context:
space:
mode:
authorHeinrich Schuchardt <xypron.glpk@gmx.de>2018-03-03 15:29:01 +0100
committerAlexander Graf <agraf@suse.de>2018-04-04 11:00:06 +0200
commit45204b1025e4e2a5cb984caab3adfdf53e658765 (patch)
tree9496c6c886af3481460b003fc00978293129e895 /cmd
parent14ad49d100a0ba4abafedf8ca6459b699c9d0fa1 (diff)
downloadu-boot-45204b1025e4e2a5cb984caab3adfdf53e658765.zip
u-boot-45204b1025e4e2a5cb984caab3adfdf53e658765.tar.gz
u-boot-45204b1025e4e2a5cb984caab3adfdf53e658765.tar.bz2
efi_loader: do_bootefi_exec should always return an EFI status code
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@gmx.de> Signed-off-by: Alexander Graf <agraf@suse.de>
Diffstat (limited to 'cmd')
-rw-r--r--cmd/bootefi.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/cmd/bootefi.c b/cmd/bootefi.c
index 3f4f214..9f02c5a 100644
--- a/cmd/bootefi.c
+++ b/cmd/bootefi.c
@@ -164,7 +164,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);
@@ -229,7 +229,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;
}