Skip to content

Commit a78c6f5

Browse files
atishp04palmer-dabbelt
authored andcommitted
RISC-V: Make sure memblock reserves the memory containing DT
Currently, the memory containing DT is not reserved. Thus, that region of memory can be reallocated or reused for other purposes. This may result in corrupted DT for nommu virt board in Qemu. We may not face any issue in kendryte as DT is embedded in the kernel image for that. Fixes: 6bd33e1 ("riscv: add nommu support") Cc: stable@vger.kernel.org Signed-off-by: Atish Patra <atish.patra@wdc.com> Signed-off-by: Palmer Dabbelt <palmerdabbelt@google.com>
1 parent 549738f commit a78c6f5

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

arch/riscv/mm/init.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -515,6 +515,7 @@ asmlinkage void __init setup_vm(uintptr_t dtb_pa)
515515
#else
516516
dtb_early_va = (void *)dtb_pa;
517517
#endif
518+
dtb_early_pa = dtb_pa;
518519
}
519520

520521
static inline void setup_vm_final(void)

0 commit comments

Comments
 (0)