1 From 67349176ca23f7525dee79665a880cde5aeeaf26 Mon Sep 17 00:00:00 2001
2 From: Nikhil Gupta <nikhil.gupta@nxp.com>
3 Date: Mon, 30 Dec 2019 15:11:23 +0530
4 Subject: [PATCH] arm64:move elfcorehdr reservation early for crash dump kernel
6 on some SOCs, elfcorehdr address may overlap with the address of reserved
7 memory allocated using early_init_fdt_scan_reserved_mem
9 Signed-off-by: Nikhil Gupta <nikhil.gupta@nxp.com>
10 Signed-off-by: Poonam Aggrwal <poonam.aggrwal@nxp.com>
12 arch/arm64/mm/init.c | 4 ++--
13 1 file changed, 2 insertions(+), 2 deletions(-)
15 --- a/arch/arm64/mm/init.c
16 +++ b/arch/arm64/mm/init.c
17 @@ -406,6 +406,8 @@ void __init arm64_memblock_init(void)
18 initrd_end = initrd_start + phys_initrd_size;
21 + reserve_elfcorehdr();
23 early_init_fdt_scan_reserved_mem();
25 /* 4GB maximum for 32-bit only capable devices */
26 @@ -416,8 +418,6 @@ void __init arm64_memblock_init(void)
28 reserve_crashkernel();
30 - reserve_elfcorehdr();
32 high_memory = __va(memblock_end_of_DRAM() - 1) + 1;
34 dma_contiguous_reserve(arm64_dma_phys_limit);