aboutsummaryrefslogtreecommitdiff
path: root/cmd/bootefi.c
diff options
context:
space:
mode:
authorTom Rini <trini@konsulko.com>2018-01-28 18:26:00 -0500
committerTom Rini <trini@konsulko.com>2018-01-28 18:26:00 -0500
commitbd39d86420434eb8139a111c2582366bc90e65c6 (patch)
tree072fe6ff300a984a8867c9d2506ed7906d435b2d /cmd/bootefi.c
parentf2ee91501892d3280a4c58093ad3a18dccd0b562 (diff)
parent29a8a2828e5c6f3f167a8526a80da992b4626daf (diff)
Merge tag 'signed-efi-next' of git://github.com/agraf/u-boot
Patch queue for efi - 2018-01-28 This is the second part of patches for 2018.03-rc1, fixing a few minor issues and adding a readme file for iSCSI booting.
Diffstat (limited to 'cmd/bootefi.c')
-rw-r--r--cmd/bootefi.c14
1 files changed, 9 insertions, 5 deletions
diff --git a/cmd/bootefi.c b/cmd/bootefi.c
index 51213c0293..4233d36b72 100644
--- a/cmd/bootefi.c
+++ b/cmd/bootefi.c
@@ -126,8 +126,9 @@ static void *copy_fdt(void *fdt)
static efi_status_t efi_do_enter(
efi_handle_t image_handle, struct efi_system_table *st,
- asmlinkage ulong (*entry)(efi_handle_t image_handle,
- struct efi_system_table *st))
+ EFIAPI efi_status_t (*entry)(
+ efi_handle_t image_handle,
+ struct efi_system_table *st))
{
efi_status_t ret = EFI_LOAD_ERROR;
@@ -138,7 +139,7 @@ static efi_status_t efi_do_enter(
}
#ifdef CONFIG_ARM64
-static efi_status_t efi_run_in_el2(asmlinkage ulong (*entry)(
+static efi_status_t efi_run_in_el2(EFIAPI efi_status_t (*entry)(
efi_handle_t image_handle, struct efi_system_table *st),
efi_handle_t image_handle, struct efi_system_table *st)
{
@@ -162,8 +163,8 @@ static efi_status_t do_bootefi_exec(void *efi, void *fdt,
struct efi_device_path *memdp = NULL;
ulong ret;
- ulong (*entry)(efi_handle_t image_handle, struct efi_system_table *st)
- asmlinkage;
+ EFIAPI efi_status_t (*entry)(efi_handle_t image_handle,
+ struct efi_system_table *st);
ulong fdt_pages, fdt_size, fdt_start, fdt_end;
const efi_guid_t fdt_guid = EFI_FDT_GUID;
bootm_headers_t img = { 0 };
@@ -372,6 +373,9 @@ static int do_bootefi(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])
saddr = argv[1];
addr = simple_strtoul(saddr, NULL, 16);
+ /* Check that a numeric value was passed */
+ if (!addr && *saddr != '0')
+ return CMD_RET_USAGE;
if (argc > 2) {
sfdt = argv[2];