diff options
author | Paul Cercueil <paul@crapouillou.net> | 2021-03-03 19:33:05 +0000 |
---|---|---|
committer | Thomas Bogendoerfer <tsbogend@alpha.franken.de> | 2021-03-08 11:49:47 +0100 |
commit | 7a05293af39fc716d0f51c0164cbb727302396a2 (patch) | |
tree | 31bd8b819760d7b72bdd090a4ab3ec6de3342fff /arch/mips/kernel | |
parent | a38fd8748464831584a19438cbb3082b5a2dab15 (diff) | |
download | lwn-7a05293af39fc716d0f51c0164cbb727302396a2.tar.gz lwn-7a05293af39fc716d0f51c0164cbb727302396a2.zip |
MIPS: boot/compressed: Copy DTB to aligned address
Since 5.12-rc1, the Device Tree blob must now be properly aligned.
Therefore, the decompress routine must be careful to copy the blob at
the next aligned address after the kernel image.
This commit fixes the kernel sometimes not booting with a Device Tree
blob appended to it.
Fixes: 79edff12060f ("scripts/dtc: Update to upstream version v1.6.0-51-g183df9e9c2b9")
Signed-off-by: Paul Cercueil <paul@crapouillou.net>
Acked-by: Rob Herring <robh@kernel.org>
Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
Diffstat (limited to 'arch/mips/kernel')
-rw-r--r-- | arch/mips/kernel/vmlinux.lds.S | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/mips/kernel/vmlinux.lds.S b/arch/mips/kernel/vmlinux.lds.S index c1c345be04ff..4b4e39b7c79b 100644 --- a/arch/mips/kernel/vmlinux.lds.S +++ b/arch/mips/kernel/vmlinux.lds.S @@ -145,6 +145,7 @@ SECTIONS } #ifdef CONFIG_MIPS_ELF_APPENDED_DTB + STRUCT_ALIGN(); .appended_dtb : AT(ADDR(.appended_dtb) - LOAD_OFFSET) { *(.appended_dtb) KEEP(*(.appended_dtb)) @@ -172,6 +173,7 @@ SECTIONS #endif #ifdef CONFIG_MIPS_RAW_APPENDED_DTB + STRUCT_ALIGN(); __appended_dtb = .; /* leave space for appended DTB */ . += 0x100000; |