diff options
author | John Crispin <john@openwrt.org> | 2014-11-03 08:00:13 +0000 |
---|---|---|
committer | John Crispin <john@openwrt.org> | 2014-11-03 08:00:13 +0000 |
commit | cc5194cf030c422ef82442091598582cf4aeca34 (patch) | |
tree | 655972cf7bc4b19a6390e84553713349a289cc56 /target/linux/ramips/image | |
parent | 101289156b4748583995d4cdb27751cea4efe917 (diff) | |
download | mtk-20170518-cc5194cf030c422ef82442091598582cf4aeca34.zip mtk-20170518-cc5194cf030c422ef82442091598582cf4aeca34.tar.gz mtk-20170518-cc5194cf030c422ef82442091598582cf4aeca34.tar.bz2 |
ramips: add support for Airlink101 AR670W
This is a RT2880-based board, 32MB RAM, 4MB flash. The bootloader
is a hacked u-Boot that reads an LZMA image directly, so we skip
generating the uImage header and enable the lzma mtdsplit parser.
Signed-off-by: Claudio Leite <leitec@staticky.com>
SVN-Revision: 43153
Diffstat (limited to 'target/linux/ramips/image')
-rw-r--r-- | target/linux/ramips/image/Makefile | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/target/linux/ramips/image/Makefile b/target/linux/ramips/image/Makefile index 759de53..1f03386 100644 --- a/target/linux/ramips/image/Makefile +++ b/target/linux/ramips/image/Makefile @@ -295,10 +295,36 @@ define BuildFirmware/Gemtek/squashfs endef BuildFirmware/Gemtek/initramfs=$(call BuildFirmware/OF/initramfs,$(1),$(2),$(3)) +# Airlink101 AR670W -- LZMA without uImage header +define BuildFirmware/AR670W/squashfs + $(call PatchKernelLzmaDtb,$(2),$(3),$(5)) + + $(eval output_name=$(IMG_PREFIX)-$(2)-$(1)-$(if $(4),$(4),sysupgrade).bin) + $(eval factory_name=$(IMG_PREFIX)-$(2)-$(1)-factory.bin) + + ( dd if=$(KDIR)/vmlinux-$(2).bin.lzma bs=65536 \ + conv=sync; dd if=$(KDIR)/root.$(1) ) > $(KDIR)/$(output_name) + + $(call prepare_generic_squashfs,$(KDIR)/$(output_name)) + + if [ `stat -c%s "$(KDIR)/$(output_name)"` \ + -gt $(ralink_default_fw_size_4M) ]; then \ + echo "Warning: $(KDIR)/$(output_name) is too big" >&2; \ + else \ + mkwrgimg -i $(KDIR)/$(output_name) \ + -d "/dev/mtdblock/2" \ + -s "wrgn16a_airlink_ar670w" \ + -o $(BIN_DIR)/$(factory_name); \ + $(CP) $(KDIR)/$(output_name) $(BIN_DIR)/$(output_name); \ + fi +endef + # # RT288X Profiles # +Image/Build/Profile/AR670W=$(call BuildFirmware/AR670W/$(1),$(1),ar670w,AR670W) + Image/Build/Profile/AR725W=$(call BuildFirmware/Gemtek/$(1),$(1),ar725w,AR725W) # 0x790000 @@ -313,6 +339,7 @@ Image/Build/Profile/WLITX4AG300N=$(call BuildFirmware/Default4M/$(1),$(1),wli-tx ifeq ($(SUBTARGET),rt288x) define Image/Build/Profile/Default + $(call Image/Build/Profile/AR670W,$(1)) $(call Image/Build/Profile/AR725W,$(1)) $(call Image/Build/Profile/F5D8235V1,$(1)) $(call Image/Build/Profile/RTN15,$(1)) |