The DIR-890L is very similar to DIR-885L, but has both USB2 and USB3. The signature for the wrgac36 board was copied from DD-Wrt. The DIR-890L bootstrap will only load the first 2 MB after the SEAMA header in the NAND flash, uncompress it with LZMA and execute it. Since the compressed kernel will not fit in 2 MB we have a problem. Solve this by putting a LZMA compressed U-Boot into the first 128 KB of the flash followed by the kernel. The bootstrap will then uncompress and execute U-Boot and then we let U-Boot read the kernel from flash and execute it. Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
23 lines
380 B
Text
23 lines
380 B
Text
. /lib/functions.sh
|
|
|
|
board=$(board_name)
|
|
|
|
kernel_size=$(sed -n 's/mtd[0-9]*: \([0-9a-f]*\).*"\(kernel\|linux\)".*/\1/p' /proc/mtd)
|
|
|
|
fixtrx() {
|
|
mtd ${kernel_size:+-c 0x$kernel_size} fixtrx firmware && exit 0
|
|
}
|
|
|
|
fixseama() {
|
|
mtd ${kernel_size:+-c 0x$kernel_size} fixseama firmware && exit 0
|
|
}
|
|
|
|
case "$board" in
|
|
dlink,dir-885l | \
|
|
dlink,dir-890l)
|
|
fixseama
|
|
;;
|
|
*)
|
|
fixtrx
|
|
;;
|
|
esac
|