Skip to content

Commit 2ccc5b1

Browse files
sladkaniralfbaechle
authored andcommitted
MIPS: Calculate VMLINUZ_LOAD_ADDRESS based on the length of vmlinux.bin
Fix VMLINUZ_LOAD_ADDRESS calculation to be based on the length of vmlinux.bin, the actual uncompressed kernel binary. Previously it was based on the length of KBUILD_IMAGE (the unstripped ELF vmlinux), which is bigger than vmlinux.bin. As a result, vmlinuz was loaded into a memory address higher then actually needed - a problem for small memory platforms. Signed-off-by: Shmulik Ladkani <shmulik.ladkani@gmail.com> To: linux-mips@linux-mips.org Cc: alex@digriz.org.uk Cc: manuel.lauss@googlemail.com Cc: sam@ravnborg.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/1564/ Acked-by: Wu Zhangjin <wuzhangjin@gmail.com> Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
1 parent 2b877a3 commit 2ccc5b1

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎arch/mips/boot/compressed/Makefile‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ $(obj)/piggy.o: $(obj)/dummy.o $(obj)/vmlinux.bin.z FORCE
5959
hostprogs-y := calc_vmlinuz_load_addr
6060

6161
VMLINUZ_LOAD_ADDRESS = $(shell $(obj)/calc_vmlinuz_load_addr \
62-
$(objtree)/$(KBUILD_IMAGE) $(VMLINUX_LOAD_ADDRESS))
62+
$(obj)/vmlinux.bin $(VMLINUX_LOAD_ADDRESS))
6363

6464
vmlinuzobjs-y += $(obj)/piggy.o
6565

0 commit comments

Comments
 (0)