Changeset 38148


Ignore:
Timestamp:
2013-09-24T07:58:34+02:00 (4 years ago)
Author:
juhosg
Message:

ar71xx: update the Image/Build/UBNT2 macro

  • append the root squashfs directly after the kernel,
  • use the 64kraw template instead of the 64k,
  • ensure that the generated images have enough erase blocks for JFFS2 garbage collection,

Tested on a WispStation M5 board.

Signed-off-by: Gabor Juhos <juhosg@…>

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/target/linux/ar71xx/image/Makefile

    r38147 r38148  
    489489 
    490490define Image/Build/UBNT2 
    491         $(call Sysupgrade/KRuImage,$(1),$(2),65536,6684672) 
    492         dd if=$(KDIR_TMP)/vmlinux-$(2).uImage of=$(KDIR_TMP)/vmlinux-$(2).uImage.bin bs=64k conv=sync 
    493         -$(STAGING_DIR_HOST)/bin/mkfwimage \ 
    494                 -B $(4) -v $(5).$(6).v6.0.0-OpenWrt-$(REVISION) \ 
    495                 -k $(KDIR_TMP)/vmlinux-$(2).uImage.bin \ 
    496                 -r $(BIN_DIR)/$(IMG_PREFIX)-root.$(1) \ 
    497                 -o $(call factoryname,$(1),$(2)) 
     491        $(eval fwsize=$(call mtdpartsize,firmware,$(3))) 
     492        $(call Sysupgrade/KRuImage,$(1),$(2),0,$$$$(($(fwsize)-4*64*1024)),64) 
     493        if [ -e "$(call sysupname,$(1),$(2))" ]; then \ 
     494                dd if=$(call sysupname,$(1),$(2)) of=$(KDIR_TMP)/$(1)-mtdpart-kernel.bin bs=1024k count=1; \ 
     495                dd if=$(call sysupname,$(1),$(2)) of=$(KDIR_TMP)/$(1)-mtdpart-rootfs.bin bs=1024k skip=1; \ 
     496                $(STAGING_DIR_HOST)/bin/mkfwimage \ 
     497                        -B $(4) -v $(5).$(6).v6.0.0-OpenWrt-$(REVISION) \ 
     498                        -k $(KDIR_TMP)/$(1)-mtdpart-kernel.bin \ 
     499                        -r $(KDIR_TMP)/$(1)-mtdpart-rootfs.bin \ 
     500                        -o $(call factoryname,$(1),$(2)); \ 
     501        fi 
    498502endef 
    499503 
     
    978982$(eval $(call SingleProfile,UAPPRO,64k,UAPPRO,ubnt-uap-pro,UAP-PRO,ttyS0,115200,BZ,BZ,ar934x)) 
    979983 
    980 $(eval $(call SingleProfile,UBDEV,64k,UBDEV01,ubdev01,UBNT-UF,ttyS0,115200,XM,XM,ar7240)) 
     984$(eval $(call SingleProfile,UBDEV,64kraw,UBDEV01,ubdev01,UBNT-UF,ttyS0,115200,XM,XM,ar7240)) 
    981985 
    982986$(eval $(call SingleProfile,UBNT,64k,UBNTRS,ubnt-rs,UBNT-RS,ttyS0,115200,RS,RSx,ar7100)) 
     
    984988$(eval $(call SingleProfile,UBNT,64k,UBNTLSSR71,ubnt-ls-sr71,UBNT-LS-SR71,ttyS0,115200,LS-SR71,LS-SR71,ar7100)) 
    985989 
    986 $(eval $(call SingleProfile,UBNTXM,64k,RW2458N,rw2458n,RW2458N,ttyS0,115200,XM,XM,ar7240)) 
    987 $(eval $(call SingleProfile,UBNTXM,64k,UBNTAIRROUTER,ubnt-airrouter,UBNT-AR,ttyS0,115200,XM,XM,ar7240)) 
    988 $(eval $(call SingleProfile,UBNTXM,64k,UBNTBULLETM,ubnt-bullet-m,UBNT-BM,ttyS0,115200,XM,XM,ar7240)) 
    989 $(eval $(call SingleProfile,UBNTXM,64k,UBNTROCKETM,ubnt-rocket-m,UBNT-RM,ttyS0,115200,XM,XM,ar7240)) 
    990 $(eval $(call SingleProfile,UBNTXM,64k,UBNTNANOM,ubnt-nano-m,UBNT-NM,ttyS0,115200,XM,XM,ar7240)) 
    991 $(eval $(call SingleProfile,UBNTXM,64k,UBNTUNIFI,ubnt-unifi,UBNT-UF,ttyS0,115200,XM,XM,ar7240)) 
    992 $(eval $(call SingleProfile,UBNTXM,64k,UBNTUNIFIOUTDOOR,ubnt-unifi-outdoor,UBNT-U20,ttyS0,115200,XM,XM,ar7240)) 
     990$(eval $(call SingleProfile,UBNTXM,64kraw,RW2458N,rw2458n,RW2458N,ttyS0,115200,XM,XM,ar7240)) 
     991$(eval $(call SingleProfile,UBNTXM,64kraw,UBNTAIRROUTER,ubnt-airrouter,UBNT-AR,ttyS0,115200,XM,XM,ar7240)) 
     992$(eval $(call SingleProfile,UBNTXM,64kraw,UBNTBULLETM,ubnt-bullet-m,UBNT-BM,ttyS0,115200,XM,XM,ar7240)) 
     993$(eval $(call SingleProfile,UBNTXM,64kraw,UBNTROCKETM,ubnt-rocket-m,UBNT-RM,ttyS0,115200,XM,XM,ar7240)) 
     994$(eval $(call SingleProfile,UBNTXM,64kraw,UBNTNANOM,ubnt-nano-m,UBNT-NM,ttyS0,115200,XM,XM,ar7240)) 
     995$(eval $(call SingleProfile,UBNTXM,64kraw,UBNTUNIFI,ubnt-unifi,UBNT-UF,ttyS0,115200,XM,XM,ar7240)) 
     996$(eval $(call SingleProfile,UBNTXM,64kraw,UBNTUNIFIOUTDOOR,ubnt-unifi-outdoor,UBNT-U20,ttyS0,115200,XM,XM,ar7240)) 
    993997 
    994998$(eval $(call SingleProfile,WHRHPG300N,64kraw,WHRG301N,whr-g301n,WHR-G301N,ttyS0,115200,$$(whrhpg300n_mtdlayout),WHR-G301N)) 
Note: See TracChangeset for help on using the changeset viewer.