summaryrefslogtreecommitdiff
path: root/arch/arm/mach-meson
diff options
context:
space:
mode:
authorMichael Walle <michael@walle.cc>2020-05-17 13:29:19 +0300
committerHeinrich Schuchardt <xypron.glpk@gmx.de>2020-05-17 22:59:53 +0300
commit714497e327e7304a2b67d5f780f415c6e1c300d0 (patch)
treed6182ed8caa040cc042b4f86a4abfaab65f68ff8 /arch/arm/mach-meson
parent515f613253cf0a892c3a321770ab927fa3d925cf (diff)
downloadu-boot-714497e327e7304a2b67d5f780f415c6e1c300d0.tar.xz
efi_loader: round the memory area in efi_add_memory_map()
Virtually all callers of this function do the rounding on their own. Some do it right, some don't. Instead of doing this in each caller, do the rounding in efi_add_memory_map(). Change the size parameter to bytes instead of pages and remove aligning and size calculation in all callers. There is no more need to make the original efi_add_memory_map() (which takes pages as size) available outside the module. Thus rename it to efi_add_memory_map_pg() and make it static to prevent further misuse outside the module. Signed-off-by: Michael Walle <michael@walle.cc> Add missing comma in sunxi_display.c. Reviewed-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Diffstat (limited to 'arch/arm/mach-meson')
-rw-r--r--arch/arm/mach-meson/board-common.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/arch/arm/mach-meson/board-common.c b/arch/arm/mach-meson/board-common.c
index bc4c92074c..747791b10e 100644
--- a/arch/arm/mach-meson/board-common.c
+++ b/arch/arm/mach-meson/board-common.c
@@ -69,11 +69,8 @@ void meson_board_add_reserved_memory(void *fdt, u64 start, u64 size)
if (ret)
printf("Could not reserve zone @ 0x%llx\n", start);
- if (IS_ENABLED(CONFIG_EFI_LOADER)) {
- efi_add_memory_map(start,
- ALIGN(size, EFI_PAGE_SIZE) >> EFI_PAGE_SHIFT,
- EFI_RESERVED_MEMORY_TYPE, false);
- }
+ if (IS_ENABLED(CONFIG_EFI_LOADER))
+ efi_add_memory_map(start, size, EFI_RESERVED_MEMORY_TYPE);
}
int meson_generate_serial_ethaddr(void)