ipq40xx: add support for Aruba AP-365
[openwrt/staging/dedeckeh.git] / target / linux / ipq40xx / image / Makefile
1 include $(TOPDIR)/rules.mk
2 include $(INCLUDE_DIR)/image.mk
3
4 DEVICE_VARS += NETGEAR_BOARD_ID NETGEAR_HW_ID
5 DEVICE_VARS += RAS_BOARD RAS_ROOTFS_SIZE RAS_VERSION
6 DEVICE_VARS += WRGG_DEVNAME WRGG_SIGNATURE
7
8 define Device/Default
9 PROFILES := Default
10 KERNEL_DEPENDS = $$(wildcard $(DTS_DIR)/$$(DEVICE_DTS).dts)
11 KERNEL_INITRAMFS_PREFIX := $$(IMG_PREFIX)-$(1)-initramfs
12 KERNEL_PREFIX := $$(IMAGE_PREFIX)
13 KERNEL_LOADADDR := 0x80208000
14 DEVICE_DTS = $$(SOC)-$(lastword $(subst _, ,$(1)))
15 SUPPORTED_DEVICES := $(subst _,$(comma),$(1))
16 IMAGE/sysupgrade.bin = sysupgrade-tar | append-metadata
17 IMAGE/sysupgrade.bin/squashfs :=
18 endef
19
20 define Device/FitImage
21 KERNEL_SUFFIX := -fit-uImage.itb
22 KERNEL = kernel-bin | gzip | fit gzip $$(DTS_DIR)/$$(DEVICE_DTS).dtb
23 KERNEL_NAME := Image
24 endef
25
26 define Device/FitImageLzma
27 KERNEL_SUFFIX := -fit-uImage.itb
28 KERNEL = kernel-bin | lzma | fit lzma $$(DTS_DIR)/$$(DEVICE_DTS).dtb
29 KERNEL_NAME := Image
30 endef
31
32 define Device/FitzImage
33 KERNEL_SUFFIX := -fit-zImage.itb
34 KERNEL = kernel-bin | fit none $$(DTS_DIR)/$$(DEVICE_DTS).dtb
35 KERNEL_NAME := zImage
36 endef
37
38 define Device/UbiFit
39 KERNEL_IN_UBI := 1
40 IMAGES := nand-factory.ubi nand-sysupgrade.bin
41 IMAGE/nand-factory.ubi := append-ubi
42 IMAGE/nand-sysupgrade.bin := sysupgrade-tar | append-metadata
43 endef
44
45 define Device/DniImage
46 KERNEL_SUFFIX := -fit-uImage.itb
47 KERNEL = kernel-bin | gzip | fit gzip $$(DTS_DIR)/$$(DEVICE_DTS).dtb
48 KERNEL_NAME := Image
49 NETGEAR_BOARD_ID :=
50 NETGEAR_HW_ID :=
51 IMAGES := factory.img sysupgrade.bin
52 IMAGE/factory.img := append-kernel | pad-offset 64k 64 | append-uImage-fakehdr filesystem | append-rootfs | pad-rootfs | netgear-dni
53 IMAGE/sysupgrade.bin := append-kernel | pad-offset 64k 64 | append-uImage-fakehdr filesystem | append-rootfs | pad-rootfs | append-metadata
54 endef
55
56 define Build/append-rootfshdr
57 mkimage -A $(LINUX_KARCH) \
58 -O linux -T filesystem \
59 -C lzma -a $(KERNEL_LOADADDR) -e $(if $(KERNEL_ENTRY),$(KERNEL_ENTRY),$(KERNEL_LOADADDR)) \
60 -n root.squashfs -d $(IMAGE_ROOTFS) $@.new
61 dd if=$@.new bs=64 count=1 >> $(IMAGE_KERNEL)
62 endef
63
64 define Build/mkmylofw_32m
65 $(eval device_id=$(word 1,$(1)))
66 $(eval revision=$(word 2,$(1)))
67
68 let \
69 size="$$(stat -c%s $@)" \
70 pad="$(subst k,* 1024,$(BLOCKSIZE))" \
71 pad="(pad - (size % pad)) % pad" \
72 newsize='size + pad'; \
73 $(STAGING_DIR_HOST)/bin/mkmylofw \
74 -B WPE72 -i 0x11f6:$(device_id):0x11f6:$(device_id) -r $(revision) \
75 -s 0x2000000 -p0x180000:$$newsize:al:0x80208000:"OpenWrt":$@ \
76 $@.new
77 @mv $@.new $@
78 endef
79
80 define Build/qsdk-ipq-factory-nand-askey
81 $(TOPDIR)/scripts/mkits-qsdk-ipq-image.sh $@.its\
82 askey_kernel $(IMAGE_KERNEL) \
83 askey_fs $(IMAGE_ROOTFS) \
84 ubifs $@
85 PATH=$(LINUX_DIR)/scripts/dtc:$(PATH) mkimage -f $@.its $@.new
86 @mv $@.new $@
87 endef
88
89 define Build/SenaoFW
90 -$(STAGING_DIR_HOST)/bin/mksenaofw \
91 -n $(BOARD_NAME) -r $(VENDOR_ID) -p $(1) \
92 -c $(DATECODE) -w $(2) -x $(CW_VER) -t 0 \
93 -e $@ \
94 -o $@.new
95 @cp $@.new $@
96 endef
97
98 define Build/wrgg-image
99 mkwrggimg -i $@ \
100 -o $@.new \
101 -d "$(WRGG_DEVNAME)" \
102 -s "$(WRGG_SIGNATURE)" \
103 -v "" -m "" -B ""
104 mv $@.new $@
105 endef
106
107 define Device/8dev_habanero-dvk
108 $(call Device/FitImageLzma)
109 DEVICE_VENDOR := 8devices
110 DEVICE_MODEL := Habanero DVK
111 IMAGE_SIZE := 30976k
112 SOC := qcom-ipq4019
113 DEVICE_PACKAGES := ipq-wifi-8dev_habanero-dvk
114 IMAGES := sysupgrade.bin
115 IMAGE/sysupgrade.bin := append-kernel | pad-to 64k | append-rootfs | pad-rootfs | append-metadata | check-size
116 endef
117 TARGET_DEVICES += 8dev_habanero-dvk
118
119 define Device/8dev_jalapeno-common
120 $(call Device/FitImage)
121 $(call Device/UbiFit)
122 BLOCKSIZE := 128k
123 PAGESIZE := 2048
124 SOC := qcom-ipq4018
125 endef
126
127 define Device/8dev_jalapeno
128 $(call Device/8dev_jalapeno-common)
129 DEVICE_VENDOR := 8devices
130 DEVICE_MODEL := Jalapeno
131 endef
132 TARGET_DEVICES += 8dev_jalapeno
133
134 define Device/alfa-network_ap120c-ac
135 $(call Device/FitImage)
136 $(call Device/UbiFit)
137 DEVICE_VENDOR := ALFA Network
138 DEVICE_MODEL := AP120C-AC
139 SOC := qcom-ipq4018
140 DEVICE_PACKAGES := kmod-usb-acm \
141 kmod-tpm-i2c-atmel uboot-envtools
142 BLOCKSIZE := 128k
143 PAGESIZE := 2048
144 IMAGE_SIZE := 65536k
145 IMAGES := nand-factory.bin nand-sysupgrade.bin
146 IMAGE/nand-factory.bin := append-ubi | qsdk-ipq-factory-nand
147 endef
148 TARGET_DEVICES += alfa-network_ap120c-ac
149
150 define Device/aruba_glenmorangie
151 $(call Device/FitImageLzma)
152 DEVICE_VENDOR := Aruba
153 SOC := qcom-ipq4029
154 DEVICE_PACKAGES := ipq-wifi-aruba_ap-303
155 IMAGES := sysupgrade.bin
156 endef
157
158 define Device/aruba_ap-303
159 $(call Device/aruba_glenmorangie)
160 DEVICE_MODEL := AP-303
161 endef
162 TARGET_DEVICES += aruba_ap-303
163
164 define Device/aruba_ap-303h
165 $(call Device/aruba_glenmorangie)
166 DEVICE_MODEL := AP-303H
167 endef
168 TARGET_DEVICES += aruba_ap-303h
169
170 define Device/aruba_ap-365
171 $(call Device/aruba_glenmorangie)
172 DEVICE_MODEL := AP-365
173 DEVICE_PACKAGES += kmod-hwmon-ad7418
174 endef
175 TARGET_DEVICES += aruba_ap-365
176
177 define Device/asus_map-ac2200
178 $(call Device/FitImageLzma)
179 DEVICE_VENDOR := ASUS
180 DEVICE_MODEL := Lyra (MAP-AC2200)
181 SOC := qcom-ipq4019
182 IMAGES := sysupgrade.bin
183 DEVICE_PACKAGES := ath10k-firmware-qca9888-ct kmod-ath3k
184 endef
185 TARGET_DEVICES += asus_map-ac2200
186
187 define Device/asus_rt-ac58u
188 $(call Device/FitImageLzma)
189 DEVICE_VENDOR := ASUS
190 DEVICE_MODEL := RT-AC58U
191 SOC := qcom-ipq4018
192 BLOCKSIZE := 128k
193 PAGESIZE := 2048
194 DTB_SIZE := 65536
195 IMAGE_SIZE := 20439364
196 FILESYSTEMS := squashfs
197 # Someone - in their infinite wisdom - decided to put the firmware
198 # version in front of the image name \03\00\00\04 => Version 3.0.0.4
199 # Since u-boot works with strings we either need another fixup step
200 # to add a version... or we are very careful not to add '\0' into that
201 # string and call it a day.... Yeah, we do the latter!
202 UIMAGE_NAME:=$(shell echo -e '\03\01\01\01RT-AC58U')
203 IMAGES := sysupgrade.bin
204 DEVICE_PACKAGES := -kmod-ath10k-ct kmod-ath10k-ct-smallbuffers \
205 kmod-usb-ledtrig-usbport
206 endef
207 TARGET_DEVICES += asus_rt-ac58u
208
209 define Device/avm_fritzbox-4040
210 $(call Device/FitImageLzma)
211 DEVICE_VENDOR := AVM
212 DEVICE_MODEL := FRITZ!Box 4040
213 SOC := qcom-ipq4018
214 BOARD_NAME := fritz4040
215 IMAGE_SIZE := 29056k
216 UBOOT_PATH := $(STAGING_DIR_IMAGE)/uboot-fritz4040.bin
217 UBOOT_PARTITION_SIZE := 524288
218 IMAGES = eva.bin sysupgrade.bin
219 IMAGE/eva.bin := append-uboot | pad-to $$$$(UBOOT_PARTITION_SIZE) | append-kernel | append-rootfs | pad-rootfs
220 IMAGE/sysupgrade.bin := append-kernel | append-rootfs | pad-rootfs | append-metadata
221 DEVICE_PACKAGES := fritz-tffs fritz-caldata
222 endef
223 TARGET_DEVICES += avm_fritzbox-4040
224
225 define Device/avm_fritzbox-7530
226 $(call Device/FitImageLzma)
227 DEVICE_VENDOR := AVM
228 DEVICE_MODEL := FRITZ!Box 7530
229 SOC := qcom-ipq4019
230 DEVICE_PACKAGES := fritz-caldata fritz-tffs-nand
231 IMAGES := sysupgrade.bin
232 endef
233 TARGET_DEVICES += avm_fritzbox-7530
234
235 define Device/avm_fritzrepeater-1200
236 $(call Device/FitImageLzma)
237 DEVICE_VENDOR := AVM
238 DEVICE_MODEL := FRITZ!Repeater 1200
239 SOC := qcom-ipq4019
240 DEVICE_PACKAGES := fritz-caldata fritz-tffs-nand ipq-wifi-avm_fritzrepeater-1200
241 IMAGES := sysupgrade.bin
242 endef
243 TARGET_DEVICES += avm_fritzrepeater-1200
244
245 define Device/avm_fritzrepeater-3000
246 $(call Device/FitImageLzma)
247 DEVICE_VENDOR := AVM
248 DEVICE_MODEL := FRITZ!Repeater 3000
249 SOC := qcom-ipq4019
250 DEVICE_PACKAGES := ath10k-firmware-qca9984-ct fritz-caldata fritz-tffs-nand
251 IMAGES := sysupgrade.bin
252 endef
253 TARGET_DEVICES += avm_fritzrepeater-3000
254
255 define Device/cellc_rtl30vw
256 KERNEL_SUFFIX := -fit-uImage.itb
257 KERNEL_INITRAMFS = kernel-bin | gzip | fit gzip $$(DTS_DIR)/$$(DEVICE_DTS).dtb
258 KERNEL = kernel-bin | gzip | fit gzip $$(DTS_DIR)/$$(DEVICE_DTS).dtb | uImage lzma | pad-to 2048
259 KERNEL_NAME := Image
260 KERNEL_IN_UBI :=
261 IMAGES := nand-factory.bin nand-sysupgrade.bin
262 IMAGE/nand-factory.bin := append-rootfshdr | append-ubi | qsdk-ipq-factory-nand-askey
263 IMAGE/nand-sysupgrade.bin := append-rootfshdr | sysupgrade-tar | append-metadata
264 DEVICE_VENDOR := Cell C
265 DEVICE_MODEL := RTL30VW
266 SOC := qcom-ipq4019
267 DEVICE_DTS_CONFIG := config@5
268 KERNEL_INSTALL := 1
269 KERNEL_SIZE := 4096k
270 IMAGE_SIZE := 57344k
271 BLOCKSIZE := 128k
272 PAGESIZE := 2048
273 DEVICE_PACKAGES := kmod-usb-net-qmi-wwan kmod-usb-serial-option uqmi ipq-wifi-cellc_rtl30vw
274 endef
275 TARGET_DEVICES += cellc_rtl30vw
276
277 define Device/cilab_meshpoint-one
278 $(call Device/8dev_jalapeno-common)
279 DEVICE_VENDOR := Crisis Innovation Lab
280 DEVICE_MODEL := MeshPoint.One
281 DEVICE_PACKAGES := kmod-i2c-gpio kmod-iio-bmp280-i2c kmod-hwmon-ina2xx kmod-rtc-pcf2127
282 endef
283 TARGET_DEVICES += cilab_meshpoint-one
284
285 define Device/compex_wpj419
286 $(call Device/FitImage)
287 $(call Device/UbiFit)
288 DEVICE_VENDOR := Compex
289 DEVICE_MODEL := WPJ419
290 SOC := qcom-ipq4019
291 DEVICE_DTS_CONFIG := config@12
292 KERNEL_INSTALL := 1
293 BLOCKSIZE := 128k
294 PAGESIZE := 2048
295 FILESYSTEMS := squashfs
296 endef
297 TARGET_DEVICES += compex_wpj419
298
299 define Device/compex_wpj428
300 $(call Device/FitImage)
301 DEVICE_VENDOR := Compex
302 DEVICE_MODEL := WPJ428
303 SOC := qcom-ipq4028
304 DEVICE_DTS_CONFIG := config@4
305 BLOCKSIZE := 64k
306 IMAGE_SIZE := 31232k
307 KERNEL_SIZE := 4096k
308 IMAGES = sysupgrade.bin cpximg-6a04.bin
309 IMAGE/sysupgrade.bin := append-kernel | append-rootfs | pad-rootfs | append-metadata
310 IMAGE/cpximg-6a04.bin := append-kernel | append-rootfs | pad-rootfs | mkmylofw_32m 0x8A2 3
311 DEVICE_PACKAGES := kmod-gpio-beeper
312 endef
313 TARGET_DEVICES += compex_wpj428
314
315 define Device/dlink_dap-2610
316 $(call Device/FitImageLzma)
317 DEVICE_VENDOR := D-Link
318 DEVICE_MODEL := DAP-2610
319 SOC := qcom-ipq4018
320 DEVICE_DTS_CONFIG := config@ap.dk01.1-c1
321 BLOCKSIZE := 64k
322 WRGG_DEVNAME := /dev/mtdblock/8
323 WRGG_SIGNATURE := wapac30_dkbs_dap2610
324 IMAGE_SIZE := 14080k
325 IMAGES := sysupgrade.bin factory.bin
326 # Bootloader expects a special 160 byte header which is added by
327 # wrgg-image.
328 # Factory image size must be larger than 6MB, and size in wrgg header must
329 # match actual factory image size to be flashable from D-Link http server.
330 # Bootloader verifies checksum of wrgg image before booting, thus jffs2
331 # cannot be part of the wrgg image. This is solved in the factory image by
332 # having the rootfs at the end of the image (without pad-rootfs). And in
333 # the sysupgrade image only the kernel is included in the wrgg checksum,
334 # but this is not flashable from the D-link http server.
335 # append-rootfs must start on an erase block boundary.
336 IMAGE/factory.bin := append-kernel | pad-offset 6144k 160 | append-rootfs | wrgg-image | check-size
337 IMAGE/sysupgrade.bin := append-kernel | wrgg-image | pad-to $$$$(BLOCKSIZE) | append-rootfs | pad-rootfs | check-size | append-metadata
338 DEVICE_PACKAGES := ipq-wifi-dlink_dap2610
339 endef
340 TARGET_DEVICES += dlink_dap-2610
341
342 define Device/engenius_eap1300
343 $(call Device/FitImage)
344 DEVICE_VENDOR := EnGenius
345 DEVICE_MODEL := EAP1300
346 DEVICE_DTS_CONFIG := config@4
347 BOARD_NAME := eap1300
348 SOC := qcom-ipq4018
349 KERNEL_SIZE := 5120k
350 IMAGE_SIZE := 25344k
351 IMAGES := sysupgrade.bin
352 IMAGE/sysupgrade.bin := append-kernel | append-rootfs | pad-rootfs | append-metadata
353 endef
354 TARGET_DEVICES += engenius_eap1300
355
356 define Device/engenius_eap2200
357 $(call Device/FitImage)
358 $(call Device/UbiFit)
359 DEVICE_VENDOR := EnGenius
360 DEVICE_MODEL := EAP2200
361 SOC := qcom-ipq4019
362 BLOCKSIZE := 128k
363 PAGESIZE := 2048
364 DEVICE_PACKAGES := ath10k-firmware-qca9888-ct ipq-wifi-engenius_eap2200 -kmod-ath10k-ct kmod-ath10k-ct-smallbuffers
365 endef
366 TARGET_DEVICES += engenius_eap2200
367
368 define Device/engenius_emd1
369 $(call Device/FitImage)
370 DEVICE_VENDOR := EnGenius
371 DEVICE_MODEL := EMD1
372 DEVICE_DTS_CONFIG := config@4
373 SOC := qcom-ipq4018
374 IMAGE_SIZE := 30720k
375 IMAGES := sysupgrade.bin factory.bin
376 IMAGE/sysupgrade.bin := append-kernel | append-rootfs | pad-rootfs | append-metadata
377 IMAGE/factory.bin := qsdk-ipq-factory-nor | check-size
378 endef
379 TARGET_DEVICES += engenius_emd1
380
381 define Device/engenius_ens620ext
382 $(call Device/FitImage)
383 DEVICE_VENDOR := EnGenius
384 DEVICE_MODEL := ENS620EXT
385 SOC := qcom-ipq4018
386 DEVICE_DTS_CONFIG := config@4
387 BLOCKSIZE := 64k
388 PAGESIZE := 256
389 BOARD_NAME := ENS620EXT
390 VENDOR_ID := 0x0101
391 PRODUCT_ID := 0x79
392 PRODUCT_ID_NEW := 0xA4
393 DATECODE := 190507
394 FW_VER := 3.1.2
395 FW_VER_NEW := 3.5.6
396 CW_VER := 1.8.99
397 IMAGE_SIZE := 21312k
398 KERNEL_SIZE := 5120k
399 FILESYSTEMS := squashfs
400 IMAGES := sysupgrade.bin factory_30.bin factory_35.bin
401 IMAGE/sysupgrade.bin := append-kernel | append-rootfs | pad-rootfs | check-size | append-metadata
402 IMAGE/factory_30.bin := append-kernel | pad-to $$$$(KERNEL_SIZE) | append-rootfs | pad-rootfs | check-size | SenaoFW $$$$(PRODUCT_ID) $$$$(FW_VER)
403 IMAGE/factory_35.bin := qsdk-ipq-factory-nor | check-size | SenaoFW $$$$(PRODUCT_ID_NEW) $$$$(FW_VER_NEW)
404 endef
405 TARGET_DEVICES += engenius_ens620ext
406
407 define Device/ezviz_cs-w3-wd1200g-eup
408 $(call Device/FitImage)
409 DEVICE_VENDOR := EZVIZ
410 DEVICE_MODEL := CS-W3-WD1200G
411 DEVICE_VARIANT := EUP
412 DEVICE_DTS_CONFIG := config@4
413 IMAGE_SIZE := 14848k
414 SOC := qcom-ipq4018
415 IMAGES := sysupgrade.bin
416 IMAGE/sysupgrade.bin := append-kernel | append-rootfs | pad-rootfs | \
417 append-metadata
418 DEVICE_PACKAGES := -kmod-ath10k-ct kmod-ath10k-ct-smallbuffers \
419 ipq-wifi-ezviz_cs-w3-wd1200g-eup
420 endef
421 TARGET_DEVICES += ezviz_cs-w3-wd1200g-eup
422
423 define Device/glinet_gl-b1300
424 $(call Device/FitImage)
425 DEVICE_VENDOR := GL.iNet
426 DEVICE_MODEL := GL-B1300
427 BOARD_NAME := gl-b1300
428 SOC := qcom-ipq4029
429 KERNEL_SIZE := 4096k
430 IMAGE_SIZE := 26624k
431 IMAGES := sysupgrade.bin
432 IMAGE/sysupgrade.bin := append-kernel |append-rootfs | pad-rootfs | append-metadata
433 endef
434 TARGET_DEVICES += glinet_gl-b1300
435
436 define Device/linksys_ea6350v3
437 # The Linksys EA6350v3 has a uboot bootloader that does not
438 # support either booting lzma kernel images nor booting UBI
439 # partitions. This uboot, however, supports raw kernel images and
440 # gzipped images.
441 #
442 # As for the time of writing this, the device will boot the kernel
443 # from a fixed address with a fixed length of 3MiB. Also, the
444 # device has a hard-coded kernel command line that requieres the
445 # rootfs and alt_rootfs to be in mtd11 and mtd13 respectively.
446 # Oh... and the kernel partition overlaps with the rootfs
447 # partition (the same for alt_kernel and alt_rootfs).
448 #
449 # If you are planing re-partitioning the device, you may want to
450 # keep those details in mind:
451 # 1. The kernel adresses you should honor are 0x00000000 and
452 # 0x02800000 respectively.
453 # 2. The kernel size (plus the dtb) cannot exceed 3.00MiB in size.
454 # 3. You can use 'zImage', but not a raw 'Image' packed with lzma.
455 # 4. The kernel command line from uboot is harcoded to boot with
456 # rootfs either in mtd11 or mtd13.
457 $(call Device/FitzImage)
458 DEVICE_VENDOR := Linksys
459 DEVICE_MODEL := EA6350
460 DEVICE_VARIANT := v3
461 SOC := qcom-ipq4018
462 BLOCKSIZE := 128k
463 PAGESIZE := 2048
464 KERNEL_SIZE := 3072k
465 IMAGE_SIZE := 37888k
466 UBINIZE_OPTS := -E 5
467 IMAGES := factory.bin sysupgrade.bin
468 IMAGE/factory.bin := append-kernel | append-uImage-fakehdr filesystem | pad-to $$$$(KERNEL_SIZE) | append-ubi | linksys-image type=EA6350v3
469 DEVICE_PACKAGES := uboot-envtools
470 endef
471 TARGET_DEVICES += linksys_ea6350v3
472
473 define Device/linksys_ea8300
474 $(call Device/FitzImage)
475 DEVICE_VENDOR := Linksys
476 DEVICE_MODEL := EA8300
477 SOC := qcom-ipq4019
478 KERNEL_SIZE := 3072k
479 IMAGE_SIZE := 87040k
480 BLOCKSIZE := 128k
481 PAGESIZE := 2048
482 UBINIZE_OPTS := -E 5 # EOD marks to "hide" factory sig at EOF
483 IMAGES := sysupgrade.bin factory.bin
484 IMAGE/factory.bin := append-kernel | pad-to $$$$(KERNEL_SIZE) | append-ubi | linksys-image type=EA8300
485 DEVICE_PACKAGES := uboot-envtools ath10k-firmware-qca9888-ct ipq-wifi-linksys_ea8300 kmod-usb-ledtrig-usbport
486 endef
487 TARGET_DEVICES += linksys_ea8300
488
489 define Device/meraki_mr33
490 $(call Device/FitImage)
491 DEVICE_VENDOR := Cisco Meraki
492 DEVICE_MODEL := MR33
493 SOC := qcom-ipq4029
494 BLOCKSIZE := 128k
495 PAGESIZE := 2048
496 IMAGES = sysupgrade.bin
497 DEVICE_PACKAGES := -swconfig ath10k-firmware-qca9887-ct
498 endef
499 TARGET_DEVICES += meraki_mr33
500
501 define Device/mobipromo_cm520-79f
502 $(call Device/FitzImage)
503 $(call Device/UbiFit)
504 DEVICE_VENDOR := MobiPromo
505 DEVICE_MODEL := CM520-79F
506 SOC := qcom-ipq4019
507 BLOCKSIZE := 128k
508 PAGESIZE := 2048
509 DEVICE_PACKAGES := ipq-wifi-mobipromo_cm520-79f kmod-usb-ledtrig-usbport
510 endef
511 TARGET_DEVICES += mobipromo_cm520-79f
512
513 define Device/netgear_ex61x0v2
514 $(call Device/DniImage)
515 DEVICE_DTS_CONFIG := config@4
516 NETGEAR_BOARD_ID := EX6150v2series
517 NETGEAR_HW_ID := 29765285+16+0+128+2x2
518 SOC := qcom-ipq4018
519 endef
520
521 define Device/netgear_ex6100v2
522 $(call Device/netgear_ex61x0v2)
523 DEVICE_VENDOR := Netgear
524 DEVICE_MODEL := EX6100
525 DEVICE_VARIANT := v2
526 endef
527 TARGET_DEVICES += netgear_ex6100v2
528
529 define Device/netgear_ex6150v2
530 $(call Device/netgear_ex61x0v2)
531 DEVICE_VENDOR := Netgear
532 DEVICE_MODEL := EX6150
533 DEVICE_VARIANT := v2
534 endef
535 TARGET_DEVICES += netgear_ex6150v2
536
537 define Device/openmesh_a42
538 $(call Device/FitImageLzma)
539 DEVICE_VENDOR := OpenMesh
540 DEVICE_MODEL := A42
541 SOC := qcom-ipq4018
542 DEVICE_DTS_CONFIG := config@om.a42
543 BLOCKSIZE := 64k
544 KERNEL = kernel-bin | lzma | fit lzma $$(DTS_DIR)/$$(DEVICE_DTS).dtb | pad-to $$(BLOCKSIZE)
545 IMAGE_SIZE := 15616k
546 IMAGES = factory.bin sysupgrade.bin
547 IMAGE/factory.bin := append-rootfs | pad-rootfs | openmesh-image ce_type=A42
548 IMAGE/sysupgrade.bin/squashfs := append-rootfs | pad-rootfs | sysupgrade-tar rootfs=$$$$@ | append-metadata
549 DEVICE_PACKAGES := uboot-envtools
550 endef
551 TARGET_DEVICES += openmesh_a42
552
553 define Device/openmesh_a62
554 $(call Device/FitImageLzma)
555 DEVICE_VENDOR := OpenMesh
556 DEVICE_MODEL := A62
557 SOC := qcom-ipq4019
558 DEVICE_DTS_CONFIG := config@om.a62
559 BLOCKSIZE := 64k
560 KERNEL = kernel-bin | lzma | fit lzma $$(DTS_DIR)/$$(DEVICE_DTS).dtb | pad-to $$(BLOCKSIZE)
561 IMAGE_SIZE := 15552k
562 IMAGES = factory.bin sysupgrade.bin
563 IMAGE/factory.bin := append-rootfs | pad-rootfs | openmesh-image ce_type=A62
564 IMAGE/sysupgrade.bin/squashfs := append-rootfs | pad-rootfs | sysupgrade-tar rootfs=$$$$@ | append-metadata
565 DEVICE_PACKAGES := ath10k-firmware-qca9888-ct uboot-envtools
566 endef
567
568 TARGET_DEVICES += openmesh_a62
569
570 define Device/qcom_ap-dk01.1-c1
571 DEVICE_VENDOR := Qualcomm Atheros
572 DEVICE_MODEL := AP-DK01.1
573 DEVICE_VARIANT := C1
574 BOARD_NAME := ap-dk01.1-c1
575 SOC := qcom-ipq4019
576 DEVICE_DTS := qcom-ipq4019-ap.dk01.1-c1
577 KERNEL_INSTALL := 1
578 KERNEL_SIZE := 4096k
579 IMAGE_SIZE := 26624k
580 $(call Device/FitImage)
581 IMAGES := sysupgrade.bin
582 IMAGE/sysupgrade.bin := append-kernel | pad-to $$$$(KERNEL_SIZE) | append-rootfs | pad-rootfs | append-metadata
583 endef
584 TARGET_DEVICES += qcom_ap-dk01.1-c1
585
586 define Device/qcom_ap-dk04.1-c1
587 $(call Device/FitImage)
588 $(call Device/UbiFit)
589 DEVICE_VENDOR := Qualcomm Atheros
590 DEVICE_MODEL := AP-DK04.1
591 DEVICE_VARIANT := C1
592 SOC := qcom-ipq4019
593 DEVICE_DTS := qcom-ipq4019-ap.dk04.1-c1
594 KERNEL_INSTALL := 1
595 KERNEL_SIZE := 4048k
596 BLOCKSIZE := 128k
597 PAGESIZE := 2048
598 BOARD_NAME := ap-dk04.1-c1
599 endef
600 TARGET_DEVICES += qcom_ap-dk04.1-c1
601
602 define Device/qxwlan_e2600ac-c1
603 $(call Device/FitImage)
604 DEVICE_VENDOR := Qxwlan
605 DEVICE_MODEL := E2600AC
606 DEVICE_VARIANT := C1
607 BOARD_NAME := e2600ac-c1
608 SOC := qcom-ipq4019
609 KERNEL_SIZE := 4096k
610 IMAGE_SIZE := 31232k
611 IMAGES := sysupgrade.bin
612 IMAGE/sysupgrade.bin := append-kernel | append-rootfs | pad-rootfs | append-metadata
613 DEVICE_PACKAGES := ipq-wifi-qxwlan_e2600ac
614 endef
615 TARGET_DEVICES += qxwlan_e2600ac-c1
616
617 define Device/qxwlan_e2600ac-c2
618 $(call Device/FitImage)
619 $(call Device/UbiFit)
620 DEVICE_VENDOR := Qxwlan
621 DEVICE_MODEL := E2600AC
622 DEVICE_VARIANT := C2
623 SOC := qcom-ipq4019
624 KERNEL_INSTALL := 1
625 BLOCKSIZE := 128k
626 PAGESIZE := 2048
627 DEVICE_PACKAGES := ipq-wifi-qxwlan_e2600ac
628 endef
629 TARGET_DEVICES += qxwlan_e2600ac-c2
630
631 define Device/unielec_u4019-32m
632 $(call Device/FitImage)
633 DEVICE_VENDOR := Unielec
634 DEVICE_MODEL := U4019
635 DEVICE_VARIANT := 32M
636 BOARD_NAME := u4019-32m
637 SOC := qcom-ipq4019
638 KERNEL_SIZE := 4096k
639 IMAGE_SIZE := 31232k
640 IMAGES := sysupgrade.bin
641 IMAGE/sysupgrade.bin := append-kernel | append-rootfs | pad-rootfs | append-metadata
642 endef
643 TARGET_DEVICES += unielec_u4019-32m
644
645 define Device/zyxel_nbg6617
646 $(call Device/FitImageLzma)
647 DEVICE_VENDOR := ZyXEL
648 DEVICE_MODEL := NBG6617
649 SOC := qcom-ipq4018
650 ROOTFS_SIZE := 24960k
651 RAS_BOARD := NBG6617
652 RAS_ROOTFS_SIZE := 19840k
653 RAS_VERSION := "$(VERSION_DIST) $(REVISION)"
654 IMAGE/sysupgrade.bin := append-kernel | append-rootfs | pad-rootfs | append-metadata
655 IMAGES := sysupgrade.bin factory.bin
656 # The ZyXEL firmware allows flashing thru the web-gui only when the rootfs is
657 # at least as large as the one of the initial firmware image (not the current
658 # one on the device). This only applies to the Web-UI, the bootlaoder ignores
659 # this minimum-size. However, the larger image can be flashed both ways.
660 IMAGE/factory.bin := append-rootfs | pad-rootfs | pad-to 64k | check-size $$$$(ROOTFS_SIZE) | zyxel-ras-image separate-kernel
661 IMAGE/sysupgrade.bin/squashfs := append-rootfs | pad-rootfs | check-size $$$$(ROOTFS_SIZE) | sysupgrade-tar rootfs=$$$$@ | append-metadata
662 DEVICE_PACKAGES := uboot-envtools kmod-usb-ledtrig-usbport
663 endef
664 TARGET_DEVICES += zyxel_nbg6617
665
666 define Device/zyxel_wre6606
667 $(call Device/FitImage)
668 DEVICE_VENDOR := ZyXEL
669 DEVICE_MODEL := WRE6606
670 DEVICE_DTS_CONFIG := config@4
671 SOC := qcom-ipq4018
672 IMAGES := sysupgrade.bin
673 IMAGE/sysupgrade.bin := append-kernel | append-rootfs | pad-rootfs | append-metadata
674 DEVICE_PACKAGES := -kmod-ath10k-ct kmod-ath10k-ct-smallbuffers
675 endef
676 TARGET_DEVICES += zyxel_wre6606
677
678 $(eval $(call BuildImage))