None of the vmlinux/uImage kernel images currently installed under
bin/ar71xx/ are directly usable for upgrading WNDR4300, as they have
incorrect u-boot magic numbers. Add a new -flashable file for this
purpose. Sample usage:
scp bin/ar71xx/openwrt-ar71xx-nand-uImage-flashable.bin router:/tmp/
ssh router
mtd -r write /tmp/openwrt-ar71xx-nand-uImage-flashable.bin /dev/mtd7
Signed-off-by: Kevin Cernekee <[email protected]>
---
target/linux/ar71xx/image/Makefile | 1 +
1 file changed, 1 insertion(+)
An alternative might involve deleting/overwriting the existing
uImage-{gzip,lzma} images - are they of any use on the NAND boxes?
Side question: the NetgearNAND kernel image is padded to exactly 2MB, the
size of /dev/mtd7, with a fake rootfs at the end:
# append the fake rootfs image to the kernel, it will reside in the last
# erase block of the kernel partition
cat $(KDIR_TMP)/fakeroot-$(2).uImage >> $(KDIR_TMP)/vmlinux-$(2).uImage
How does this work if there is a bad block in mtd7?
diff --git a/target/linux/ar71xx/image/Makefile
b/target/linux/ar71xx/image/Makefile
index 8234f88..0eec5b0 100644
--- a/target/linux/ar71xx/image/Makefile
+++ b/target/linux/ar71xx/image/Makefile
@@ -834,6 +834,7 @@ define Image/Build/NetgearNAND/buildkernel
# append the fake rootfs image to the kernel, it will reside in the last
# erase block of the kernel partition
cat $(KDIR_TMP)/fakeroot-$(2).uImage >> $(KDIR_TMP)/vmlinux-$(2).uImage
+ cp $(KDIR_TMP)/vmlinux-$(2).uImage $(UIMAGE)-flashable.bin
endef
--
1.7.9.5
_______________________________________________
openwrt-devel mailing list
[email protected]
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel