bmips: Build U-Boot into the XG6846 target main master
authorLinus Walleij <linus.walleij@linaro.org>
Sat, 5 Aug 2023 07:02:20 +0000 (09:02 +0200)
committerLinus Walleij <linus.walleij@linaro.org>
Wed, 1 May 2024 19:32:23 +0000 (21:32 +0200)
commit219018185e52a49b6a676a3591fe28406bb1a062
tree1d35014298a4c804163bd540340904783a07c141
parentf789454df1146aa426d6cc28fc61b005ecfb82c3
bmips: Build U-Boot into the XG6846 target

It appears that the CFE boot loader found in the XG6846
cannot load kernels over a certain size, and the old
relocate hack is not working.

What to do? We can build a small U-Boot into the image,
make CFE boot that, place the kernel immediately after
U-Boot, and use U-Boot to boot the system instead.

The compiled u-boot.bin becomes around ~300KB and with
LZMA compression it will swiftly fit into 128KB, so
we use two 64KB erase blocks right after the CFE to
store an imagetag:ed U-Boot.

Reviewed-by: Paul Donald <newtwen+github@gmail.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
target/linux/bmips/dts/bcm6328-inteno-xg6846.dts
target/linux/bmips/image/Makefile
target/linux/bmips/image/bcm6328.mk