ramips: make the relocation address configurable

If no argument is given to relocate-kernel, KERNEL_LOADADDR will be used
just as before.

This is a preparation for ramips support of ipTIME AX2004M.

Signed-off-by: Sungbo Eo <mans0n@gorani.run>
This commit is contained in:
Sungbo Eo 2022-01-29 23:24:07 +09:00
parent 6ff970bb51
commit 03aa57d7ab

View File

@ -113,7 +113,7 @@ endef
define Build/relocate-kernel define Build/relocate-kernel
rm -rf $@.relocate rm -rf $@.relocate
$(CP) ../../generic/image/relocate $@.relocate $(CP) ../../generic/image/relocate $@.relocate
$(MAKE) -C $@.relocate KERNEL_ADDR=$(KERNEL_LOADADDR) CROSS_COMPILE=$(TARGET_CROSS) $(MAKE) -C $@.relocate KERNEL_ADDR=$(if $(1),$(1),$(KERNEL_LOADADDR)) CROSS_COMPILE=$(TARGET_CROSS)
( \ ( \
dd if=$@.relocate/loader.bin bs=32 conv=sync && \ dd if=$@.relocate/loader.bin bs=32 conv=sync && \
perl -e '@s = stat("$@"); print pack("V", @s[7])' && \ perl -e '@s = stat("$@"); print pack("V", @s[7])' && \