The return type of efi_add_memory_map() has been updated to return
efi_status_t as a result we should check the return of efi_add_memory_map()
against EFI_SUCCESS as opposed to the original input addr parameter.
This change will also remove this error message on raspberrypi 3 boot: "FDT
memrsv map 0: Failed to add to map".
Fixes: 416e07e2cfcf ("efi: Drop error return in efi_carve_out_dt_rsv()")
Cc: Heinrich Schuchardt <[email protected]>
Cc: Alexander Graf <[email protected]>
Signed-off-by: Bryan O'Donoghue <[email protected]>
---
cmd/bootefi.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/cmd/bootefi.c b/cmd/bootefi.c
index c19256e00d..04d3e3e4a7 100644
--- a/cmd/bootefi.c
+++ b/cmd/bootefi.c
@@ -169,8 +169,8 @@ static void efi_carve_out_dt_rsv(void *fdt)
pages = efi_size_in_pages(size + (addr & EFI_PAGE_MASK));
addr &= ~EFI_PAGE_MASK;
- if (!efi_add_memory_map(addr, pages, EFI_RESERVED_MEMORY_TYPE,
- false))
+ if (efi_add_memory_map(addr, pages, EFI_RESERVED_MEMORY_TYPE,
+ false) != EFI_SUCCESS)
printf("FDT memrsv map %d: Failed to add to map\n", i);
}
}
--
2.22.0
_______________________________________________
U-Boot mailing list
[email protected]
https://lists.denx.de/listinfo/u-boot