Skip to content

Commit 74b5a63

Browse files
jonasjelonekhauke
authored andcommitted
realtek: image: add rt-loader-no-uimage recipe
Add a new recipe 'rt-loader-no-uimage' that passes the kernel load address to rt-loader, causing it to use that instead of it's initial run address. The usual behavior is fine for uImages where the load address is predefined in the header, U-boot loads the image to that address and then runs it, rt-loader just takes over that address. For non-uImage instead, the address is tightly coupled to where the image has been transferred during serial or TFTP upload. This may not be possible on several devices. Passing a separate kernel load address to rt-loader decouples that and avoids taking the pain to change the load address of the kernel itself. Signed-off-by: Jonas Jelonek <[email protected]> Link: openwrt/openwrt#21248 Signed-off-by: Hauke Mehrtens <[email protected]>
1 parent b1c1b71 commit 74b5a63

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

target/linux/realtek/image/Makefile

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,13 @@ define Build/rt-loader
3030
mv "$@.new" "$@"
3131
endef
3232

33+
define Build/rt-loader-no-uimage
34+
$(MAKE) all clean -C rt-loader CROSS_COMPILE="$(TARGET_CROSS)" \
35+
KERNEL_ADDR="$(KERNEL_LOADADDR)" KERNEL_IMG_IN="$@" \
36+
KERNEL_IMG_OUT="$@.new" BUILD_DIR="$@.build"
37+
mv "$@.new" "$@"
38+
endef
39+
3340
define Build/zyxel-vers
3441
( echo VERS;\
3542
for hw in $(ZYXEL_VERS); do\

0 commit comments

Comments
 (0)