X-Git-Url: http://git.openwrt.org/?a=blobdiff_plain;f=target%2Flinux%2Fath79%2Fimage%2Fgeneric.mk;h=b33a578f19938d38373cef14f411008556e8dac2;hb=55b4b3655263984b92e4b9fc515a5e6b8003c655;hp=bda47ce74da35696035db22c2f0b9609b8cbb67d;hpb=4a0cc5d4ef29a11914850c72158aca1e2a170fb0;p=openwrt%2Fopenwrt.git diff --git a/target/linux/ath79/image/generic.mk b/target/linux/ath79/image/generic.mk index bda47ce74d..b33a578f19 100644 --- a/target/linux/ath79/image/generic.mk +++ b/target/linux/ath79/image/generic.mk @@ -35,7 +35,7 @@ define Build/addpattern endef define Build/append-md5sum-bin - $(STAGING_DIR_HOST)/bin/mkhash md5 $@ | sed 's/../\\\\x&/g' |\ + $(MKHASH) md5 $@ | sed 's/../\\\\x&/g' |\ xargs echo -ne >> $@ endef @@ -142,11 +142,20 @@ define Build/teltonika-fw-fake-checksum # from begin of the firmware file) with 16 bytes stored just before # 0xdeadc0de marker. Values are only compared, MD5 sum is not verified. let \ - offs="$$(stat -c%s $@) - 20"; \ + offs="$$(stat -c%s $@) - $(1)"; \ dd if=$@ bs=1 count=16 skip=76 |\ dd of=$@ bs=1 count=16 seek=$$offs conv=notrunc endef +define Build/teltonika-v1-header + $(STAGING_DIR_HOST)/bin/mktplinkfw \ + -c -H $(TPLINK_HWID) -W $(TPLINK_HWREV) -L $(KERNEL_LOADADDR) \ + -E $(if $(KERNEL_ENTRY),$(KERNEL_ENTRY),$(KERNEL_LOADADDR)) \ + -m $(TPLINK_HEADER_VERSION) -N "$(VERSION_DIST)" -V "RUT2xx " \ + -k $@ -o $@.new $(1) + @mv $@.new $@ +endef + define Build/wrgg-pad-rootfs $(STAGING_DIR_HOST)/bin/padjffs2 $(IMAGE_ROOTFS) -c 64 >>$@ endef @@ -163,7 +172,7 @@ define Device/seama # - 36 bytes of META data (4-bytes aligned) IMAGE/default := append-kernel | pad-offset $$$$(BLOCKSIZE) 64 | append-rootfs IMAGE/sysupgrade.bin := $$(IMAGE/default) | seama | pad-rootfs | \ - append-metadata | check-size + check-size | append-metadata IMAGE/factory.bin := $$(IMAGE/default) | pad-rootfs -x 64 | seama | \ seama-seal | check-size SEAMA_SIGNATURE := @@ -290,11 +299,14 @@ endef TARGET_DEVICES += alfa-network_r36a define Device/allnet_all-wap02860ac + $(Device/senao_loader_okli) SOC := qca9558 DEVICE_VENDOR := ALLNET DEVICE_MODEL := ALL-WAP02860AC DEVICE_PACKAGES := ath10k-firmware-qca988x-ct kmod-ath10k-ct - IMAGE_SIZE := 13120k + IMAGE_SIZE := 11584k + LOADER_FLASH_OFFS := 0x220000 + SENAO_IMGNAME := senao-allwap02860ac endef TARGET_DEVICES += allnet_all-wap02860ac @@ -324,7 +336,7 @@ define Device/avm KERNEL_INITRAMFS := $$(KERNEL) IMAGE/sysupgrade.bin := append-kernel | pad-to 64k | \ append-squashfs-fakeroot-be | pad-to 256 | append-rootfs | pad-rootfs | \ - append-metadata | check-size + check-size | append-metadata DEVICE_PACKAGES := fritz-tffs endef @@ -550,6 +562,16 @@ define Device/comfast_cf-e314n-v2 endef TARGET_DEVICES += comfast_cf-e314n-v2 +define Device/comfast_cf-e375ac + SOC := qca9563 + DEVICE_VENDOR := COMFAST + DEVICE_MODEL := CF-E375AC + DEVICE_PACKAGES := kmod-ath10k-ct \ + ath10k-firmware-qca9888-ct -uboot-envtools + IMAGE_SIZE := 16000k +endef +TARGET_DEVICES += comfast_cf-e375ac + define Device/comfast_cf-e5 SOC := qca9531 DEVICE_VENDOR := COMFAST @@ -651,6 +673,15 @@ define Device/compex_wpj563 endef TARGET_DEVICES += compex_wpj563 +define Device/devolo_dlan-pro-1200plus-ac + SOC := ar9344 + DEVICE_VENDOR := Devolo + DEVICE_MODEL := dLAN pro 1200+ WiFi ac + DEVICE_PACKAGES := kmod-ath10k-ct ath10k-firmware-qca988x-ct + IMAGE_SIZE := 15872k +endef +TARGET_DEVICES += devolo_dlan-pro-1200plus-ac + define Device/devolo_dvl1200e SOC := qca9558 DEVICE_VENDOR := devolo @@ -746,7 +777,7 @@ define Device/dlink_dap-2xxx IMAGE/factory.img := append-kernel | pad-offset 6144k 160 | \ append-rootfs | wrgg-pad-rootfs | mkwrggimg | check-size IMAGE/sysupgrade.bin := append-kernel | mkwrggimg | \ - pad-to $$$$(BLOCKSIZE) | append-rootfs | append-metadata | check-size + pad-to $$$$(BLOCKSIZE) | append-rootfs | check-size | append-metadata KERNEL := kernel-bin | append-dtb | relocate-kernel | lzma KERNEL_INITRAMFS := $$(KERNEL) | mkwrggimg endef @@ -798,7 +829,7 @@ define Device/dlink_dap-2695-a1 IMAGE/factory.img := $$(IMAGE/default) | append-rootfs | wrgg-pad-rootfs | \ mkwrggimg | check-size IMAGE/sysupgrade.bin := $$(IMAGE/default) | mkwrggimg | append-rootfs | \ - wrgg-pad-rootfs | append-metadata | check-size + wrgg-pad-rootfs | check-size | append-metadata KERNEL := kernel-bin | append-dtb | relocate-kernel | lzma KERNEL_INITRAMFS := $$(KERNEL) | mkwrggimg DAP_SIGNATURE := wapac02_dkbs_dap2695 @@ -860,7 +891,7 @@ define Device/dlink_dir-825-b1 DEVICE_VARIANT := B1 IMAGE_SIZE := 6208k IMAGE/sysupgrade.bin := append-kernel | append-rootfs | pad-rootfs | \ - append-metadata | check-size + check-size | append-metadata DEVICE_PACKAGES := kmod-usb-ohci kmod-usb2 kmod-usb-ledtrig-usbport \ kmod-leds-reset kmod-owl-loader SUPPORTED_DEVICES += dir-825-b1 @@ -881,8 +912,7 @@ define Device/dlink_dir-825-c1 pad-rootfs IMAGE/factory.bin := $$(IMAGE/default) | pad-offset $$$$(IMAGE_SIZE) 26 | \ append-string 00DB120AR9344-RT-101214-00 | check-size - IMAGE/sysupgrade.bin := $$(IMAGE/default) | append-metadata | \ - check-size + IMAGE/sysupgrade.bin := $$(IMAGE/default) | check-size | append-metadata endef TARGET_DEVICES += dlink_dir-825-c1 @@ -899,8 +929,7 @@ define Device/dlink_dir-835-a1 pad-rootfs IMAGE/factory.bin := $$(IMAGE/default) | pad-offset $$$$(IMAGE_SIZE) 26 | \ append-string 00DB120AR9344-RT-101214-00 | check-size - IMAGE/sysupgrade.bin := $$(IMAGE/default) | append-metadata | \ - check-size + IMAGE/sysupgrade.bin := $$(IMAGE/default) | check-size | append-metadata endef TARGET_DEVICES += dlink_dir-835-a1 @@ -919,7 +948,7 @@ define Device/dlink_dir-842-c IMAGE/default := append-kernel | uImage lzma | \ pad-offset $$$$(BLOCKSIZE) 64 | append-rootfs IMAGE/sysupgrade.bin := $$(IMAGE/default) | seama | pad-rootfs | \ - append-metadata | check-size + check-size | append-metadata IMAGE/factory.bin := $$(IMAGE/default) | pad-rootfs -x 64 | seama | \ seama-seal | check-size IMAGE_SIZE := 15680k @@ -1332,7 +1361,7 @@ define Device/jjplus_ja76pf2 IMAGE/kernel.bin := append-kernel IMAGE/rootfs.bin := append-rootfs | pad-rootfs IMAGE/sysupgrade.bin := append-rootfs | pad-rootfs | combined-image | \ - append-metadata | check-size + check-size | append-metadata KERNEL := kernel-bin | append-dtb | lzma | pad-to $$(BLOCKSIZE) KERNEL_INITRAMFS := kernel-bin | append-dtb IMAGE_SIZE := 16000k @@ -1340,6 +1369,15 @@ define Device/jjplus_ja76pf2 endef TARGET_DEVICES += jjplus_ja76pf2 +define Device/joyit_jt-or750i + SOC := qca9531 + DEVICE_VENDOR := Joy-IT + DEVICE_MODEL := JT-OR750i + DEVICE_PACKAGES := kmod-ath10k-ct ath10k-firmware-qca9887-ct + IMAGE_SIZE := 16000k +endef +TARGET_DEVICES += joyit_jt-or750i + define Device/librerouter_librerouter-v1 SOC := qca9558 DEVICE_VENDOR := Librerouter @@ -1395,20 +1433,37 @@ define Device/mercury_mw4530r-v1 endef TARGET_DEVICES += mercury_mw4530r-v1 +define Device/nec_wx1200cr + DEVICE_VENDOR := NEC + IMAGE/default := append-kernel | pad-offset $$$$(BLOCKSIZE) 64 | append-rootfs + IMAGE/sysupgrade.bin := $$(IMAGE/default) | seama | pad-rootfs | \ + check-size | append-metadata + DEVICE_PACKAGES := kmod-ath10k-ct ath10k-firmware-qca9888-ct +endef + +define Device/nec_wf1200cr + $(Device/nec_wx1200cr) + SOC := qca9561 + DEVICE_MODEL := Aterm WF1200CR + IMAGE_SIZE := 7680k + SEAMA_MTDBLOCK := 5 + SEAMA_SIGNATURE := wrgac62_necpf.2016gui_wf1200cr + IMAGES += factory.bin + IMAGE/factory.bin := $$(IMAGE/default) | pad-rootfs -x 64 | seama | \ + seama-seal | nec-enc ryztfyutcrqqo69d | check-size +endef +TARGET_DEVICES += nec_wf1200cr + define Device/nec_wg1200cr + $(Device/nec_wx1200cr) SOC := qca9563 - DEVICE_VENDOR := NEC DEVICE_MODEL := Aterm WG1200CR IMAGE_SIZE := 7616k SEAMA_MTDBLOCK := 6 SEAMA_SIGNATURE := wrgac72_necpf.2016gui_wg1200cr IMAGES += factory.bin - IMAGE/default := append-kernel | pad-offset $$$$(BLOCKSIZE) 64 | append-rootfs - IMAGE/sysupgrade.bin := $$(IMAGE/default) | seama | pad-rootfs | \ - append-metadata | check-size IMAGE/factory.bin := $$(IMAGE/default) | pad-rootfs -x 64 | seama | \ seama-seal | nec-enc 9gsiy9nzep452pad | check-size - DEVICE_PACKAGES := kmod-ath10k-ct ath10k-firmware-qca9888-ct endef TARGET_DEVICES += nec_wg1200cr @@ -1434,10 +1489,8 @@ define Device/netgear_ex6400_ex7300 IMAGE_SIZE := 15552k IMAGE/default := append-kernel | pad-offset $$$$(BLOCKSIZE) 64 | \ netgear-rootfs | pad-rootfs - IMAGE/sysupgrade.bin := $$(IMAGE/default) | append-metadata | \ - check-size - IMAGE/factory.img := $$(IMAGE/default) | netgear-dni | \ - check-size + IMAGE/sysupgrade.bin := $$(IMAGE/default) | check-size | append-metadata + IMAGE/factory.img := $$(IMAGE/default) | netgear-dni | check-size DEVICE_PACKAGES := kmod-ath10k-ct ath10k-firmware-qca99x0-ct endef @@ -1615,6 +1668,26 @@ define Device/openmesh_common_256k openmesh-image ce_type=$$$$(OPENMESH_CE_TYPE) | append-metadata endef +define Device/openmesh_a40 + $(Device/openmesh_common_64k) + SOC := qca9558 + DEVICE_MODEL := A40 + DEVICE_PACKAGES += kmod-ath10k-ct ath10k-firmware-qca988x-ct kmod-usb2 + OPENMESH_CE_TYPE := A60 + SUPPORTED_DEVICES += a40 +endef +TARGET_DEVICES += openmesh_a40 + +define Device/openmesh_a60 + $(Device/openmesh_common_64k) + SOC := qca9558 + DEVICE_MODEL := A60 + DEVICE_PACKAGES += kmod-ath10k-ct ath10k-firmware-qca988x-ct kmod-usb2 + OPENMESH_CE_TYPE := A60 + SUPPORTED_DEVICES += a60 +endef +TARGET_DEVICES += openmesh_a60 + define Device/openmesh_mr600-v1 $(Device/openmesh_common_64k) SOC := ar9344 @@ -1800,7 +1873,7 @@ define Device/phicomm_k2t DEVICE_MODEL := K2T IMAGE_SIZE := 15744k IMAGE/sysupgrade.bin := append-kernel | append-rootfs | pad-rootfs | \ - append-metadata | check-size + check-size | append-metadata DEVICE_PACKAGES := kmod-leds-reset kmod-ath10k-ct-smallbuffers ath10k-firmware-qca9888-ct endef TARGET_DEVICES += phicomm_k2t @@ -1867,6 +1940,43 @@ define Device/plasmacloud_pa300e endef TARGET_DEVICES += plasmacloud_pa300e +define Device/qca_ap143 + SOC := qca9533 + DEVICE_VENDOR := Qualcomm Atheros + DEVICE_MODEL := AP143 + DEVICE_PACKAGES := kmod-usb2 + SUPPORTED_DEVICES += ap143 + LOADER_TYPE := bin + LOADER_FLASH_OFFS := 0x50000 + KERNEL := kernel-bin | append-dtb | lzma | uImage lzma -M 0x4f4b4c49 + COMPILE := loader-$(1).bin loader-$(1).uImage + COMPILE/loader-$(1).bin := loader-okli-compile + COMPILE/loader-$(1).uImage := append-loader-okli $(1) | pad-to 64k | lzma | \ + uImage lzma +endef + +define Device/qca_ap143-8m + $(Device/qca_ap143) + DEVICE_VARIANT := (8M) + IMAGE_SIZE := 7744k + IMAGES += factory.bin + IMAGE/factory.bin := append-kernel | pad-to $$$$(BLOCKSIZE) | \ + append-rootfs | pad-rootfs | check-size | pad-to 6336k | \ + append-loader-okli-uimage $(1) | pad-to 64k +endef +TARGET_DEVICES += qca_ap143-8m + +define Device/qca_ap143-16m + $(Device/qca_ap143) + DEVICE_VARIANT := (16M) + IMAGE_SIZE := 15936k + IMAGES += factory.bin + IMAGE/factory.bin := append-kernel | pad-to $$$$(BLOCKSIZE) | \ + append-rootfs | pad-rootfs | check-size | pad-to 14528k | \ + append-loader-okli-uimage $(1) | pad-to 64k +endef +TARGET_DEVICES += qca_ap143-16m + define Device/qihoo_c301 $(Device/seama) SOC := ar9344 @@ -2086,6 +2196,28 @@ define Device/telco_t1 endef TARGET_DEVICES += telco_t1 +define Device/teltonika_rut230-v1 + SOC := ar9331 + DEVICE_VENDOR := Teltonika + DEVICE_MODEL := RUT230 + DEVICE_VARIANT := v1 + DEVICE_PACKAGES := kmod-usb-chipidea2 kmod-usb-acm kmod-usb-net-qmi-wwan \ + uqmi -uboot-envtools + IMAGE_SIZE := 15552k + TPLINK_HWID := 0x32200002 + TPLINK_HWREV := 0x1 + TPLINK_HEADER_VERSION := 1 + KERNEL := kernel-bin | append-dtb | lzma | teltonika-v1-header + KERNEL_INITRAMFS := kernel-bin | append-dtb | lzma | uImage lzma + IMAGES += factory.bin + IMAGE/factory.bin := append-kernel | pad-to $$$$(BLOCKSIZE) | append-rootfs |\ + pad-rootfs | pad-extra 64 | teltonika-fw-fake-checksum 54 | check-size + IMAGE/sysupgrade.bin := append-kernel | pad-to $$$$(BLOCKSIZE) |\ + append-rootfs | pad-rootfs | append-metadata |\ + check-size +endef +TARGET_DEVICES += teltonika_rut230-v1 + define Device/teltonika_rut955 SOC := ar9344 DEVICE_VENDOR := Teltonika @@ -2100,11 +2232,10 @@ define Device/teltonika_rut955 KERNEL_INITRAMFS := kernel-bin | append-dtb | lzma | uImage lzma IMAGES += factory.bin IMAGE/factory.bin := append-kernel | pad-to $$$$(BLOCKSIZE) | append-rootfs |\ - pad-rootfs | teltonika-fw-fake-checksum | append-string master |\ + pad-rootfs | teltonika-fw-fake-checksum 20 | append-string master |\ append-md5sum-bin | check-size IMAGE/sysupgrade.bin := append-kernel | pad-to $$$$(BLOCKSIZE) |\ - append-rootfs | pad-rootfs | append-metadata |\ - check-size + append-rootfs | pad-rootfs | check-size | append-metadata endef TARGET_DEVICES += teltonika_rut955 @@ -2127,8 +2258,7 @@ define Device/trendnet_tew-823dru pad-rootfs IMAGE/factory.bin := $$(IMAGE/default) | pad-offset $$$$(IMAGE_SIZE) 26 | \ append-string 00AP135AR9558-RT-131129-00 | check-size - IMAGE/sysupgrade.bin := $$(IMAGE/default) | append-metadata | \ - check-size + IMAGE/sysupgrade.bin := $$(IMAGE/default) | check-size | append-metadata endef TARGET_DEVICES += trendnet_tew-823dru @@ -2178,6 +2308,15 @@ define Device/winchannel_wb2000 endef TARGET_DEVICES += winchannel_wb2000 +define Device/xiaomi_aiot-ac2350 + SOC := qca9563 + DEVICE_VENDOR := Xiaomi + DEVICE_MODEL := AIoT AC2350 + DEVICE_PACKAGES := kmod-ath10k-ct ath10k-firmware-qca9984-ct + IMAGE_SIZE := 14336k +endef +TARGET_DEVICES += xiaomi_aiot-ac2350 + define Device/xiaomi_mi-router-4q SOC := qca9561 DEVICE_VENDOR := Xiaomi @@ -2219,6 +2358,15 @@ define Device/yuncore_xd4200 endef TARGET_DEVICES += yuncore_xd4200 +define Device/ziking_cpe46b + SOC := ar9330 + DEVICE_VENDOR := ZiKing + DEVICE_MODEL := CPE46B + IMAGE_SIZE := 8000k + DEVICE_PACKAGES := kmod-i2c-gpio +endef +TARGET_DEVICES += ziking_cpe46b + define Device/zbtlink_zbt-wd323 SOC := ar9344 DEVICE_VENDOR := ZBT