ar71xx: add rssileds to WA850RE v1 image
[openwrt/openwrt.git] / target / linux / ar71xx / image / tp-link.mk
1 DEVICE_VARS += LOADER_FLASH_OFFS TPLINK_BOARD_ID TPLINK_FLASHLAYOUT TPLINK_HEADER_VERSION TPLINK_HWID TPLINK_HWREV
2
3 define Build/copy-file
4 cat "$(1)" > "$@"
5 endef
6
7 define Build/loader-okli
8 dd if=$(KDIR)/loader-$(1).gz bs=7680 conv=sync of="$@.new"
9 cat "$@" >> "$@.new"
10 mv "$@.new" "$@"
11 endef
12
13 define Build/loader-okli-compile
14 $(call Build/loader-common,FLASH_OFFS=$(LOADER_FLASH_OFFS) FLASH_MAX=0 KERNEL_CMDLINE="$(CMDLINE)")
15 endef
16
17 # combine kernel and rootfs into one image
18 # mktplinkfw <type> <optional extra arguments to mktplinkfw binary>
19 # <type> is "sysupgrade" or "factory"
20 #
21 # -a align the rootfs start on an <align> bytes boundary
22 # -j add jffs2 end-of-filesystem markers
23 # -s strip padding from end of the image
24 # -X reserve <size> bytes in the firmware image (hexval prefixed with 0x)
25 define Build/mktplinkfw
26 -$(STAGING_DIR_HOST)/bin/mktplinkfw \
27 -H $(TPLINK_HWID) -W $(TPLINK_HWREV) -F $(TPLINK_FLASHLAYOUT) -N OpenWrt -V $(REVISION) \
28 -m $(TPLINK_HEADER_VERSION) \
29 -k $(IMAGE_KERNEL) \
30 -r $@ \
31 -o $@.new \
32 -j -X 0x40000 \
33 -a $(call rootfs_align,$(FILESYSTEM)) \
34 $(wordlist 2,$(words $(1)),$(1)) \
35 $(if $(findstring sysupgrade,$(word 1,$(1))),-s) && mv $@.new $@ || rm -f $@
36 endef
37
38 define Build/uImageArcher
39 mkimage -A $(LINUX_KARCH) \
40 -O linux -T kernel \
41 -C $(1) -a $(KERNEL_LOADADDR) -e $(if $(KERNEL_ENTRY),$(KERNEL_ENTRY),$(KERNEL_LOADADDR)) \
42 -n '$(call toupper,$(LINUX_KARCH)) LEDE Linux-$(LINUX_VERSION)' -d $@ $@.new
43 @mv $@.new $@
44 endef
45
46
47 define Device/tplink
48 TPLINK_HWREV := 0x1
49 TPLINK_HEADER_VERSION := 1
50 LOADER_TYPE := gz
51 KERNEL := kernel-bin | patch-cmdline | lzma
52 KERNEL_INITRAMFS := kernel-bin | patch-cmdline | lzma | tplink-v1-header
53 IMAGES := sysupgrade.bin factory.bin
54 IMAGE/sysupgrade.bin := append-rootfs | mktplinkfw sysupgrade
55 IMAGE/factory.bin := append-rootfs | mktplinkfw factory
56 endef
57
58 define Device/tplink-nolzma
59 $(Device/tplink)
60 LOADER_FLASH_OFFS := 0x22000
61 COMPILE := loader-$(1).gz
62 COMPILE/loader-$(1).gz := loader-okli-compile
63 KERNEL := copy-file $(KDIR)/vmlinux.bin.lzma | uImage lzma -M 0x4f4b4c49 | loader-okli $(1)
64 KERNEL_INITRAMFS := copy-file $(KDIR)/vmlinux-initramfs.bin.lzma | loader-kernel-cmdline | tplink-v1-header
65 endef
66
67 define Device/tplink-4m
68 $(Device/tplink-nolzma)
69 TPLINK_FLASHLAYOUT := 4M
70 IMAGE_SIZE := 3904k
71 endef
72
73 define Device/tplink-8m
74 $(Device/tplink-nolzma)
75 TPLINK_FLASHLAYOUT := 8M
76 IMAGE_SIZE := 7936k
77 endef
78
79 define Device/tplink-4mlzma
80 $(Device/tplink)
81 TPLINK_FLASHLAYOUT := 4Mlzma
82 IMAGE_SIZE := 3904k
83 endef
84
85 define Device/tplink-8mlzma
86 $(Device/tplink)
87 TPLINK_FLASHLAYOUT := 8Mlzma
88 IMAGE_SIZE := 7936k
89 endef
90
91 define Device/tplink-16mlzma
92 $(Device/tplink)
93 TPLINK_FLASHLAYOUT := 16Mlzma
94 IMAGE_SIZE := 15872k
95 endef
96
97 define Device/archer-cxx
98 KERNEL := kernel-bin | patch-cmdline | lzma | uImageArcher lzma
99 IMAGES := sysupgrade.bin factory.bin
100 IMAGE/sysupgrade.bin := append-rootfs | tplink-safeloader sysupgrade | \
101 append-metadata | check-size $$$$(IMAGE_SIZE)
102 IMAGE/factory.bin := append-rootfs | tplink-safeloader factory
103 endef
104
105 define Device/archer-c25-v1
106 $(Device/archer-cxx)
107 DEVICE_TITLE := TP-LINK Archer C25 v1
108 DEVICE_PACKAGES := kmod-ath10k ath10k-firmware-qca9887
109 BOARDNAME := ARCHER-C25-V1
110 TPLINK_BOARD_ID := ARCHER-C25-V1
111 DEVICE_PROFILE := ARCHERC25V1
112 IMAGE_SIZE := 7808k
113 LOADER_TYPE := elf
114 MTDPARTS := spi0.0:128k(factory-uboot)ro,64k(u-boot)ro,1536k(kernel),6272k(rootfs),128k(config)ro,64k(art)ro,7808k@0x30000(firmware)
115 SUPPORTED_DEVICES := archer-c25-v1
116 endef
117
118 define Device/archer-c58-v1
119 $(Device/archer-cxx)
120 DEVICE_TITLE := TP-LINK Archer C58 v1
121 DEVICE_PACKAGES := kmod-ath10k
122 BOARDNAME := ARCHER-C58-V1
123 TPLINK_BOARD_ID := ARCHER-C58-V1
124 DEVICE_PROFILE := ARCHERC58V1
125 IMAGE_SIZE := 7936k
126 MTDPARTS := spi0.0:64k(u-boot)ro,64k(mac)ro,1344k(kernel),6592k(rootfs),64k(tplink)ro,64k(art)ro,7936k@0x20000(firmware)
127 SUPPORTED_DEVICES := archer-c58-v1
128 endef
129
130 define Device/archer-c59-v1
131 $(Device/archer-cxx)
132 DEVICE_TITLE := TP-LINK Archer C59 v1
133 DEVICE_PACKAGES := kmod-usb-core kmod-usb2 kmod-usb-ledtrig-usbport kmod-ath10k ath10k-firmware-qca988x
134 BOARDNAME := ARCHER-C59-V1
135 TPLINK_BOARD_ID := ARCHER-C59-V1
136 DEVICE_PROFILE := ARCHERC59V1
137 IMAGE_SIZE := 14528k
138 MTDPARTS := spi0.0:64k(u-boot)ro,64k(mac)ro,1536k(kernel),12992k(rootfs),1664k(tplink)ro,64k(art)ro,14528k@0x20000(firmware)
139 SUPPORTED_DEVICES := archer-c59-v1
140 endef
141
142 define Device/archer-c60-v1
143 $(Device/archer-cxx)
144 DEVICE_TITLE := TP-LINK Archer C60 v1
145 DEVICE_PACKAGES := kmod-ath10k ath10k-firmware-qca988x
146 BOARDNAME := ARCHER-C60-V1
147 TPLINK_BOARD_ID := ARCHER-C60-V1
148 DEVICE_PROFILE := ARCHERC60V1
149 IMAGE_SIZE := 7936k
150 MTDPARTS := spi0.0:64k(u-boot)ro,64k(mac)ro,1344k(kernel),6592k(rootfs),64k(tplink)ro,64k(art)ro,7936k@0x20000(firmware)
151 SUPPORTED_DEVICES := archer-c60-v1
152 endef
153 TARGET_DEVICES += archer-c25-v1 archer-c58-v1 archer-c59-v1 archer-c60-v1
154
155 define Device/archer-c5-v1
156 $(Device/tplink-16mlzma)
157 DEVICE_TITLE := TP-LINK Archer C5 v1
158 DEVICE_PACKAGES := kmod-usb-core kmod-usb2 kmod-usb-ledtrig-usbport kmod-ath10k ath10k-firmware-qca988x
159 BOARDNAME := ARCHER-C5
160 DEVICE_PROFILE := ARCHERC7
161 TPLINK_HWID := 0xc5000001
162 endef
163
164 define Device/archer-c7-v1
165 $(Device/tplink-8mlzma)
166 DEVICE_TITLE := TP-LINK Archer C7 v1
167 DEVICE_PACKAGES := kmod-usb-core kmod-usb2 kmod-usb-ledtrig-usbport kmod-ath10k ath10k-firmware-qca988x
168 BOARDNAME := ARCHER-C7
169 DEVICE_PROFILE := ARCHERC7
170 TPLINK_HWID := 0x75000001
171 endef
172
173 define Device/archer-c7-v2
174 $(Device/tplink-16mlzma)
175 DEVICE_TITLE := TP-LINK Archer C7 v2
176 DEVICE_PACKAGES := kmod-usb-core kmod-usb2 kmod-usb-ledtrig-usbport kmod-ath10k ath10k-firmware-qca988x
177 BOARDNAME := ARCHER-C7-V2
178 DEVICE_PROFILE := ARCHERC7
179 TPLINK_HWID := 0xc7000002
180 IMAGES := sysupgrade.bin factory.bin factory-us.bin factory-eu.bin
181 IMAGE/factory-us.bin := append-rootfs | mktplinkfw factory -C US
182 IMAGE/factory-eu.bin := append-rootfs | mktplinkfw factory -C EU
183 endef
184
185 define Device/archer-c7-v2-il
186 $(Device/tplink-16mlzma)
187 DEVICE_TITLE := TP-LINK Archer C7 v2 (IL)
188 DEVICE_PACKAGES := kmod-usb-core kmod-usb2 kmod-usb-ledtrig-usbport kmod-ath10k ath10k-firmware-qca988x
189 BOARDNAME := ARCHER-C7-V2
190 DEVICE_PROFILE := ARCHERC7
191 TPLINK_HWID := 0xc7000002
192 TPLINK_HWREV := 0x494c0001
193 endef
194
195 define Device/tl-wdr7500-v3
196 $(Device/tplink-8mlzma)
197 DEVICE_TITLE := TP-LINK Archer C7 v3
198 DEVICE_PACKAGES := kmod-usb-core kmod-usb2 kmod-usb-ledtrig-usbport kmod-ath10k ath10k-firmware-qca988x
199 BOARDNAME := ARCHER-C7
200 DEVICE_PROFILE := ARCHERC7
201 TPLINK_HWID := 0x75000003
202 endef
203 TARGET_DEVICES += archer-c5-v1 archer-c7-v1 archer-c7-v2 archer-c7-v2-il tl-wdr7500-v3
204
205 define Device/cpe510-520-v1
206 DEVICE_TITLE := TP-LINK CPE510/520 v1
207 DEVICE_PACKAGES := rssileds
208 MTDPARTS := spi0.0:128k(u-boot)ro,64k(pation-table)ro,64k(product-info)ro,1536k(kernel),6144k(rootfs),192k(config)ro,64k(ART)ro,7680k@0x40000(firmware)
209 IMAGE_SIZE := 7680k
210 BOARDNAME := CPE510
211 TPLINK_BOARD_ID := CPE510
212 DEVICE_PROFILE := CPE510
213 LOADER_TYPE := elf
214 KERNEL := kernel-bin | patch-cmdline | lzma | loader-kernel
215 IMAGES := sysupgrade.bin factory.bin
216 IMAGE/sysupgrade.bin := append-rootfs | tplink-safeloader sysupgrade
217 IMAGE/factory.bin := append-rootfs | tplink-safeloader factory
218 endef
219
220 define Device/cpe210-220-v1
221 $(Device/cpe510-520-v1)
222 DEVICE_TITLE := TP-LINK CPE210/220 v1
223 BOARDNAME := CPE210
224 TPLINK_BOARD_ID := CPE210
225 endef
226
227 define Device/wbs210-v1
228 $(Device/cpe510-520-v1)
229 DEVICE_TITLE := TP-LINK WBS210 v1
230 BOARDNAME := WBS210
231 TPLINK_BOARD_ID := WBS210
232 endef
233
234 define Device/wbs510-v1
235 $(Device/cpe510-520-v1)
236 DEVICE_TITLE := TP-LINK WBS510 v1
237 BOARDNAME := WBS510
238 TPLINK_BOARD_ID := WBS510
239 endef
240 TARGET_DEVICES += cpe210-220-v1 cpe510-520-v1 wbs210-v1 wbs510-v1
241
242 define Device/eap120-v1
243 DEVICE_TITLE := TP-LINK EAP120 v1
244 MTDPARTS := spi0.0:128k(u-boot)ro,64k(pation-table)ro,64k(product-info)ro,1536k(kernel),14336k(rootfs),192k(config)ro,64k(ART)ro,15872k@0x40000(firmware)
245 IMAGE_SIZE := 15872k
246 BOARDNAME := EAP120
247 TPLINK_BOARD_ID := EAP120
248 DEVICE_PROFILE := EAP120
249 LOADER_TYPE := elf
250 KERNEL := kernel-bin | patch-cmdline | lzma | loader-kernel
251 IMAGES := sysupgrade.bin factory.bin
252 IMAGE/sysupgrade.bin := append-rootfs | tplink-safeloader sysupgrade
253 IMAGE/factory.bin := append-rootfs | tplink-safeloader factory
254 endef
255 TARGET_DEVICES += eap120-v1
256
257 define Device/re450-v1
258 DEVICE_TITLE := TP-LINK RE450 v1
259 DEVICE_PACKAGES := kmod-ath10k ath10k-firmware-qca988x
260 MTDPARTS := spi0.0:128k(u-boot)ro,1344k(kernel),4672k(rootfs),64k(pation-table)ro,64k(product-info)ro,1856k(config)ro,64k(art)ro,6016k@0x20000(firmware)
261 IMAGE_SIZE := 7936k
262 BOARDNAME := RE450
263 TPLINK_BOARD_ID := RE450
264 DEVICE_PROFILE := RE450
265 LOADER_TYPE := elf
266 TPLINK_HWID := 0x0
267 TPLINK_HWREV := 0
268 TPLINK_HEADER_VERSION := 1
269 KERNEL := kernel-bin | patch-cmdline | lzma | tplink-v1-header
270 IMAGES := sysupgrade.bin factory.bin
271 IMAGE/sysupgrade.bin := append-rootfs | tplink-safeloader sysupgrade
272 IMAGE/factory.bin := append-rootfs | tplink-safeloader factory
273 endef
274 TARGET_DEVICES += re450-v1
275
276 define Device/tl-mr10u-v1
277 $(Device/tplink-4mlzma)
278 DEVICE_TITLE := TP-LINK TL-MR10U v1
279 DEVICE_PACKAGES := kmod-usb-core kmod-usb2
280 BOARDNAME := TL-MR10U
281 DEVICE_PROFILE := TLMR10U
282 TPLINK_HWID := 0x00100101
283 CONSOLE := ttyATH0,115200
284 endef
285
286 define Device/tl-mr11u-v1
287 $(Device/tplink-4mlzma)
288 DEVICE_TITLE := TP-LINK TL-MR11U v1
289 DEVICE_PACKAGES := kmod-usb-core kmod-usb2 kmod-usb-ledtrig-usbport
290 BOARDNAME := TL-MR11U
291 DEVICE_PROFILE := TLMR11U
292 TPLINK_HWID := 0x00110101
293 CONSOLE := ttyATH0,115200
294 endef
295
296 define Device/tl-mr11u-v2
297 $(Device/tl-mr11u-v1)
298 DEVICE_TITLE := TP-LINK TL-MR11U v2
299 TPLINK_HWID := 0x00110102
300 endef
301
302 define Device/tl-mr12u-v1
303 $(Device/tplink-4mlzma)
304 DEVICE_TITLE := TP-LINK TL-MR12U v1
305 DEVICE_PACKAGES := kmod-usb-core kmod-usb2 kmod-usb-ledtrig-usbport
306 BOARDNAME := TL-MR13U
307 DEVICE_PROFILE := TLMR12U
308 TPLINK_HWID := 0x00120101
309 CONSOLE := ttyATH0,115200
310 endef
311
312 define Device/tl-mr13u-v1
313 $(Device/tl-mr12u-v1)
314 DEVICE_TITLE := TP-LINK TL-MR13U v1
315 DEVICE_PROFILE := TLMR13U
316 TPLINK_HWID := 0x00130101
317 endef
318 TARGET_DEVICES += tl-mr10u-v1 tl-mr11u-v1 tl-mr11u-v2 tl-mr12u-v1 tl-mr13u-v1
319
320 define Device/tl-mr3020-v1
321 $(Device/tplink-4mlzma)
322 DEVICE_TITLE := TP-LINK TL-MR3020 v1
323 DEVICE_PACKAGES := kmod-usb-core kmod-usb2 kmod-usb-ledtrig-usbport
324 BOARDNAME := TL-MR3020
325 DEVICE_PROFILE := TLMR3020
326 TPLINK_HWID := 0x30200001
327 CONSOLE := ttyATH0,115200
328 endef
329
330 define Device/tl-mr3040-v1
331 $(Device/tl-mr3020-v1)
332 DEVICE_TITLE := TP-LINK TL-MR3040 v1
333 BOARDNAME := TL-MR3040
334 DEVICE_PROFILE := TLMR3040
335 TPLINK_HWID := 0x30400001
336 endef
337
338 define Device/tl-mr3040-v2
339 $(Device/tl-mr3040-v1)
340 DEVICE_TITLE := TP-LINK TL-MR3040 v2
341 BOARDNAME := TL-MR3040-v2
342 TPLINK_HWID := 0x30400002
343 endef
344
345 define Device/tl-mr3220-v1
346 $(Device/tplink-4m)
347 DEVICE_TITLE := TP-LINK TL-MR3220 v1
348 DEVICE_PACKAGES := kmod-usb-core kmod-usb2 kmod-usb-ledtrig-usbport
349 BOARDNAME := TL-MR3220
350 DEVICE_PROFILE := TLMR3220
351 TPLINK_HWID := 0x32200001
352 endef
353
354 define Device/tl-mr3220-v2
355 $(Device/tplink-4mlzma)
356 DEVICE_TITLE := TP-LINK TL-MR3220 v2
357 DEVICE_PACKAGES := kmod-usb-core kmod-usb2 kmod-usb-ledtrig-usbport
358 BOARDNAME := TL-MR3220-v2
359 DEVICE_PROFILE := TLMR3220
360 TPLINK_HWID := 0x32200002
361 CONSOLE := ttyATH0,115200
362 endef
363
364 define Device/tl-mr3420-v1
365 $(Device/tplink-4m)
366 DEVICE_TITLE := TP-LINK TL-MR3420 v1
367 DEVICE_PACKAGES := kmod-usb-core kmod-usb2 kmod-usb-ledtrig-usbport
368 BOARDNAME := TL-MR3420
369 DEVICE_PROFILE := TLMR3420
370 TPLINK_HWID := 0x34200001
371 endef
372
373 define Device/tl-mr3420-v2
374 $(Device/tplink-4mlzma)
375 DEVICE_TITLE := TP-LINK TL-MR3420 v2
376 DEVICE_PACKAGES := kmod-usb-core kmod-usb2 kmod-usb-ledtrig-usbport
377 BOARDNAME := TL-MR3420-v2
378 DEVICE_PROFILE := TLMR3420
379 TPLINK_HWID := 0x34200002
380 endef
381 TARGET_DEVICES += tl-mr3020-v1 tl-mr3040-v1 tl-mr3040-v2 tl-mr3220-v1 tl-mr3220-v2 tl-mr3420-v1 tl-mr3420-v2
382
383 define Device/tl-mr6400-v1
384 $(Device/tplink-8mlzma)
385 DEVICE_TITLE := TP-LINK TL-MR6400 v1
386 DEVICE_PACKAGES := kmod-usb-core kmod-usb2 kmod-usb-net kmod-usb-net-rndis kmod-usb-serial kmod-usb-serial-option adb-enablemodem
387 BOARDNAME := TL-MR6400
388 DEVICE_PROFILE := TLMR6400
389 TPLINK_HWID := 0x64000001
390 endef
391 TARGET_DEVICES += tl-mr6400-v1
392
393 define Device/tl-wa701nd-v1
394 $(Device/tplink-4m)
395 DEVICE_TITLE := TP-LINK TL-WA701N/ND v1
396 BOARDNAME := TL-WA901ND
397 DEVICE_PROFILE := TLWA701
398 TPLINK_HWID := 0x07010001
399 endef
400
401 define Device/tl-wa701nd-v2
402 $(Device/tplink-4mlzma)
403 DEVICE_TITLE := TP-LINK TL-WA701N/ND v2
404 BOARDNAME := TL-WA701ND-v2
405 DEVICE_PROFILE := TLWA701
406 TPLINK_HWID := 0x07010002
407 CONSOLE := ttyATH0,115200
408 endef
409
410 define Device/tl-wa7210n-v2
411 $(Device/tplink-4mlzma)
412 DEVICE_TITLE := TP-LINK TL-WA7210N v2
413 DEVICE_PACKAGES := rssileds kmod-ledtrig-netdev
414 BOARDNAME := TL-WA7210N-v2
415 DEVICE_PROFILE := TLWA7210
416 TPLINK_HWID := 0x72100002
417 CONSOLE := ttyATH0,115200
418 endef
419
420 define Device/tl-wa730re-v1
421 $(Device/tplink-4m)
422 DEVICE_TITLE := TP-LINK TL-WA730RE v1
423 BOARDNAME := TL-WA901ND
424 DEVICE_PROFILE := TLWA730RE
425 TPLINK_HWID := 0x07300001
426 endef
427
428 define Device/tl-wa750re-v1
429 $(Device/tplink-4mlzma)
430 DEVICE_TITLE := TP-LINK TL-WA750RE v1
431 DEVICE_PACKAGES := rssileds
432 BOARDNAME := TL-WA750RE
433 DEVICE_PROFILE := TLWA750
434 TPLINK_HWID := 0x07500001
435 endef
436
437 define Device/tl-wa7510n-v1
438 $(Device/tplink-4m)
439 DEVICE_TITLE := TP-LINK TL-WA7510N v1
440 BOARDNAME := TL-WA7510N
441 DEVICE_PROFILE := TLWA7510
442 TPLINK_HWID := 0x75100001
443 endef
444 TARGET_DEVICES += tl-wa701nd-v1 tl-wa701nd-v2 tl-wa7210n-v2 tl-wa730re-v1 tl-wa750re-v1 tl-wa7510n-v1
445
446 define Device/tl-wa801nd-v1
447 $(Device/tplink-4m)
448 DEVICE_TITLE := TP-LINK TL-WA801N/ND v1
449 BOARDNAME := TL-WA901ND
450 DEVICE_PROFILE := TLWA801
451 TPLINK_HWID := 0x08010001
452 endef
453
454 define Device/tl-wa801nd-v2
455 $(Device/tplink-4mlzma)
456 DEVICE_TITLE := TP-LINK TL-WA801N/ND v2
457 BOARDNAME := TL-WA801ND-v2
458 DEVICE_PROFILE := TLWA801
459 TPLINK_HWID := 0x08010002
460 endef
461
462 define Device/tl-wa801nd-v3
463 $(Device/tplink-4mlzma)
464 DEVICE_TITLE := TP-LINK TL-WA801N/ND v3
465 BOARDNAME := TL-WA801ND-v3
466 DEVICE_PROFILE := TLWA801
467 TPLINK_HWID := 0x08010003
468 endef
469
470 define Device/tl-wa830re-v1
471 $(Device/tplink-4m)
472 DEVICE_TITLE := TP-LINK TL-WA830RE v1
473 BOARDNAME := TL-WA901ND
474 DEVICE_PROFILE := TLWA830
475 TPLINK_HWID := 0x08300010
476 endef
477
478 define Device/tl-wa830re-v2
479 $(Device/tplink-4mlzma)
480 DEVICE_TITLE := TP-LINK TL-WA830RE v2
481 BOARDNAME := TL-WA830RE-v2
482 DEVICE_PROFILE := TLWA830
483 TPLINK_HWID := 0x08300002
484 endef
485
486 define Device/tl-wa850re-v1
487 $(Device/tplink-4mlzma)
488 DEVICE_TITLE := TP-LINK TL-WA850RE v1
489 DEVICE_PACKAGES := rssileds
490 BOARDNAME := TL-WA850RE
491 DEVICE_PROFILE := TLWA850
492 TPLINK_HWID := 0x08500001
493 endef
494
495 define Device/tl-wa85xre
496 $(Device/tplink)
497 TPLINK_HWREV := 0
498 KERNEL := kernel-bin | patch-cmdline | lzma | tplink-v1-header
499 IMAGE/sysupgrade.bin := append-rootfs | tplink-safeloader sysupgrade
500 IMAGE/factory.bin := append-rootfs | tplink-safeloader factory
501 MTDPARTS := spi0.0:128k(u-boot)ro,1344k(kernel),2304k(rootfs),256k(config)ro,64k(art)ro,3648k@0x20000(firmware)
502 endef
503
504 define Device/tl-wa850re-v2
505 $(Device/tl-wa85xre)
506 DEVICE_TITLE := TP-LINK TL-WA850RE v2
507 DEVICE_PACKAGES := rssileds
508 BOARDNAME := TL-WA850RE-V2
509 DEVICE_PROFILE := TLWA850
510 TPLINK_BOARD_ID := TLWA850REV2
511 TPLINK_HWID := 0x08500002
512 endef
513
514 define Device/tl-wa855re-v1
515 $(Device/tl-wa85xre)
516 DEVICE_TITLE := TP-LINK TL-WA855RE v1
517 BOARDNAME := TL-WA855RE-v1
518 DEVICE_PROFILE := TLWA855RE
519 TPLINK_HWID := 0x08550001
520 TPLINK_BOARD_ID := TLWA855REV1
521 endef
522
523 define Device/tl-wa860re-v1
524 $(Device/tplink-4mlzma)
525 DEVICE_TITLE := TP-LINK TL-WA860RE v1
526 BOARDNAME := TL-WA860RE
527 DEVICE_PROFILE := TLWA860
528 TPLINK_HWID := 0x08600001
529 endef
530 TARGET_DEVICES += tl-wa801nd-v1 tl-wa801nd-v2 tl-wa801nd-v3 tl-wa830re-v1 tl-wa830re-v2 tl-wa850re-v1 tl-wa850re-v2 tl-wa855re-v1 tl-wa860re-v1
531
532 define Device/tl-wa901nd-v1
533 $(Device/tplink-4m)
534 DEVICE_TITLE := TP-LINK TL-WA901N/ND v1
535 BOARDNAME := TL-WA901ND
536 DEVICE_PROFILE := TLWA901
537 TPLINK_HWID := 0x09010001
538 endef
539
540 define Device/tl-wa901nd-v2
541 $(Device/tplink-4m)
542 DEVICE_TITLE := TP-LINK TL-WA901N/ND v2
543 BOARDNAME := TL-WA901ND-v2
544 DEVICE_PROFILE := TLWA901
545 TPLINK_HWID := 0x09010002
546 endef
547
548 define Device/tl-wa901nd-v3
549 $(Device/tplink-4mlzma)
550 DEVICE_TITLE := TP-LINK TL-WA901N/ND v3
551 BOARDNAME := TL-WA901ND-v3
552 DEVICE_PROFILE := TLWA901
553 TPLINK_HWID := 0x09010003
554 endef
555
556 define Device/tl-wa901nd-v4
557 $(Device/tplink-4mlzma)
558 DEVICE_TITLE := TP-LINK TL-WA901N/ND v4
559 BOARDNAME := TL-WA901ND-v4
560 DEVICE_PROFILE := TLWA901
561 TPLINK_HWID := 0x09010004
562 IMAGE/factory.bin := append-rootfs | mktplinkfw factory -C EU
563 endef
564 TARGET_DEVICES += tl-wa901nd-v1 tl-wa901nd-v2 tl-wa901nd-v3 tl-wa901nd-v4
565
566 define Device/tl-wdr3320-v2
567 $(Device/tplink-4mlzma)
568 DEVICE_TITLE := TP-LINK TL-WDR3320 v2
569 DEVICE_PACKAGES := kmod-usb-core kmod-usb2 kmod-usb-ledtrig-usbport
570 BOARDNAME := TL-WDR3320-v2
571 DEVICE_PROFILE := TLWDR3320V2
572 TPLINK_HWID := 0x33200002
573 TPLINK_HEADER_VERSION := 2
574 endef
575
576 define Device/tl-wdr3500-v1
577 $(Device/tplink-8mlzma)
578 DEVICE_TITLE := TP-LINK TL-WDR3500 v1
579 DEVICE_PACKAGES := kmod-usb-core kmod-usb2 kmod-usb-ledtrig-usbport
580 BOARDNAME := TL-WDR3500
581 DEVICE_PROFILE := TLWDR4300
582 TPLINK_HWID := 0x35000001
583 endef
584
585 define Device/tl-wdr3600-v1
586 $(Device/tl-wdr3500-v1)
587 DEVICE_TITLE := TP-LINK TL-WDR3600 v1
588 BOARDNAME := TL-WDR4300
589 TPLINK_HWID := 0x36000001
590 IMAGE/factory.bin := append-rootfs | mktplinkfw factory -C US
591 endef
592
593 define Device/tl-wdr4300-v1
594 $(Device/tl-wdr3600-v1)
595 DEVICE_TITLE := TP-LINK TL-WDR4300 v1
596 TPLINK_HWID := 0x43000001
597 endef
598
599 define Device/tl-wdr4300-v1-il
600 $(Device/tl-wdr3500-v1)
601 DEVICE_TITLE := TP-LINK TL-WDR4300 v1 (IL)
602 BOARDNAME := TL-WDR4300
603 TPLINK_HWID := 0x43008001
604 endef
605
606 define Device/tl-wdr4310-v1
607 $(Device/tl-wdr4300-v1-il)
608 DEVICE_TITLE := TP-LINK TL-WDR4310 v1
609 TPLINK_HWID := 0x43100001
610 endef
611
612 define Device/tl-wdr4900-v2
613 $(Device/tplink-8mlzma)
614 DEVICE_TITLE := TP-LINK TL-WDR4900 v2
615 DEVICE_PACKAGES := kmod-usb-core kmod-usb2 kmod-usb-ledtrig-usbport
616 BOARDNAME := TL-WDR4900-v2
617 DEVICE_PROFILE := TLWDR4900V2
618 TPLINK_HWID := 0x49000002
619 endef
620
621 define Device/tl-wdr6500-v2
622 $(Device/tplink-8mlzma)
623 DEVICE_TITLE := TP-LINK TL-WDR6500 v2
624 DEVICE_PACKAGES := kmod-usb-core kmod-usb2 kmod-usb-ledtrig-usbport kmod-ath10k ath10k-firmware-qca988x
625 KERNEL := kernel-bin | patch-cmdline | lzma | uImage lzma
626 KERNEL_INITRAMFS := kernel-bin | patch-cmdline | lzma | uImage lzma | tplink-v1-header
627 BOARDNAME := TL-WDR6500-v2
628 DEVICE_PROFILE := TLWDR6500V2
629 TPLINK_HWID := 0x65000002
630 TPLINK_HEADER_VERSION := 2
631 endef
632
633 define Device/mw4530r-v1
634 $(Device/tl-wdr4300-v1)
635 DEVICE_TITLE := Mercury MW4530R v1
636 TPLINK_HWID := 0x45300001
637 endef
638 TARGET_DEVICES += tl-wdr3320-v2 tl-wdr3500-v1 tl-wdr3600-v1 tl-wdr4300-v1 tl-wdr4300-v1-il tl-wdr4310-v1 tl-wdr4900-v2 tl-wdr6500-v2 mw4530r-v1
639
640 define Device/tl-wpa8630-v1
641 $(Device/tplink-8mlzma)
642 DEVICE_TITLE := TP-LINK TL-WPA8630 v1
643 DEVICE_PACKAGES := kmod-ath10k ath10k-firmware-qca988x
644 BOARDNAME := TL-WPA8630
645 DEVICE_PROFILE := TL-WPA8630
646 TPLINK_HWID := 0x86300001
647 endef
648 TARGET_DEVICES += tl-wpa8630-v1
649
650 define Device/tl-wr1041n-v2
651 $(Device/tplink-4mlzma)
652 DEVICE_TITLE := TP-LINK TL-WR1041N v2
653 BOARDNAME := TL-WR1041N-v2
654 DEVICE_PROFILE := TLWR1041
655 TPLINK_HWID := 0x10410002
656 endef
657 TARGET_DEVICES += tl-wr1041n-v2
658
659 define Device/tl-wr1043nd-v1
660 $(Device/tplink-8m)
661 DEVICE_TITLE := TP-LINK TL-WR1043N/ND v1
662 DEVICE_PACKAGES := kmod-usb-core kmod-usb2 kmod-usb-ledtrig-usbport
663 BOARDNAME := TL-WR1043ND
664 DEVICE_PROFILE := TLWR1043
665 TPLINK_HWID := 0x10430001
666 endef
667
668 define Device/tl-wr1043nd-v2
669 $(Device/tplink-8mlzma)
670 DEVICE_TITLE := TP-LINK TL-WR1043N/ND v2
671 DEVICE_PACKAGES := kmod-usb-core kmod-usb2 kmod-usb-ledtrig-usbport
672 BOARDNAME := TL-WR1043ND-v2
673 DEVICE_PROFILE := TLWR1043
674 TPLINK_HWID := 0x10430002
675 endef
676
677 define Device/tl-wr1043nd-v3
678 $(Device/tl-wr1043nd-v2)
679 DEVICE_TITLE := TP-LINK TL-WR1043N/ND v3
680 TPLINK_HWID := 0x10430003
681 endef
682
683 define Device/tl-wr1043nd-v4
684 $(Device/tplink)
685 DEVICE_TITLE := TP-LINK TL-WR1043N/ND v4
686 DEVICE_PACKAGES := kmod-usb-core kmod-usb2 kmod-usb-ledtrig-usbport
687 BOARDNAME := TL-WR1043ND-v4
688 DEVICE_PROFILE := TLWR1043
689 TPLINK_HWID := 0x10430004
690 MTDPARTS := spi0.0:128k(u-boot)ro,1536k(kernel),14016k(rootfs),128k(product-info)ro,320k(config)ro,64k(partition-table)ro,128k(logs)ro,64k(ART)ro,15552k@0x20000(firmware)
691 IMAGE_SIZE := 15552k
692 TPLINK_BOARD_ID := TLWR1043NDV4
693 KERNEL := kernel-bin | patch-cmdline | lzma | tplink-v1-header
694 IMAGES := sysupgrade.bin factory.bin
695 IMAGE/sysupgrade.bin := append-rootfs | tplink-safeloader sysupgrade
696 IMAGE/factory.bin := append-rootfs | tplink-safeloader factory
697 endef
698
699 define Device/tl-wr2543-v1
700 $(Device/tplink-8mlzma)
701 DEVICE_TITLE := TP-LINK TL-WR2543N/ND v1
702 DEVICE_PACKAGES := kmod-usb-core kmod-usb2 kmod-usb-ledtrig-usbport
703 BOARDNAME := TL-WR2543N
704 DEVICE_PROFILE := TLWR2543
705 TPLINK_HWID := 0x25430001
706 IMAGE/sysupgrade.bin := append-rootfs | mktplinkfw sysupgrade -v 3.13.99
707 IMAGE/factory.bin := append-rootfs | mktplinkfw factory -v 3.13.99
708 endef
709 TARGET_DEVICES += tl-wr1043nd-v1 tl-wr1043nd-v2 tl-wr1043nd-v3 tl-wr1043nd-v4 tl-wr2543-v1
710
711 define Device/tl-wr703n-v1
712 $(Device/tplink-4mlzma)
713 DEVICE_TITLE := TP-LINK TL-WR703N v1
714 DEVICE_PACKAGES := kmod-usb-core kmod-usb2
715 BOARDNAME := TL-WR703N
716 DEVICE_PROFILE := TLWR703
717 TPLINK_HWID := 0x07030101
718 CONSOLE := ttyATH0,115200
719 endef
720
721 define Device/tl-wr710n-v1
722 $(Device/tplink-8mlzma)
723 DEVICE_TITLE := TP-LINK TL-WR710N v1
724 DEVICE_PACKAGES := kmod-usb-core kmod-usb2
725 BOARDNAME := TL-WR710N
726 DEVICE_PROFILE := TLWR710
727 TPLINK_HWID := 0x07100001
728 CONSOLE := ttyATH0,115200
729 IMAGE/factory.bin := append-rootfs | mktplinkfw factory -C US
730 endef
731
732 define Device/tl-wr710n-v2
733 $(Device/tplink-4mlzma)
734 DEVICE_TITLE := TP-LINK TL-WR710N v2
735 DEVICE_PACKAGES := kmod-usb-core kmod-usb2
736 BOARDNAME := TL-WR710N
737 DEVICE_PROFILE := TLWR710
738 TPLINK_HWID := 0x07100002
739 CONSOLE := ttyATH0,115200
740 endef
741
742 define Device/tl-wr710n-v2.1
743 $(Device/tl-wr710n-v1)
744 DEVICE_TITLE := TP-LINK TL-WR710N v2.1
745 TPLINK_HWID := 0x07100002
746 TPLINK_HWREV := 0x00000002
747 endef
748
749 define Device/tl-wr720n-v3
750 $(Device/tplink-4mlzma)
751 DEVICE_TITLE := TP-LINK TL-WR720N v3
752 DEVICE_PACKAGES := kmod-usb-core kmod-usb2
753 BOARDNAME := TL-WR720N-v3
754 DEVICE_PROFILE := TLWR720
755 TPLINK_HWID := 0x07200103
756 CONSOLE := ttyATH0,115200
757 endef
758
759 define Device/tl-wr720n-v4
760 $(Device/tl-wr720n-v3)
761 DEVICE_TITLE := TP-LINK TL-WR720N v4
762 TPLINK_HWID := 0x07200104
763 endef
764 TARGET_DEVICES += tl-wr703n-v1 tl-wr710n-v1 tl-wr710n-v2 tl-wr710n-v2.1 tl-wr720n-v3 tl-wr720n-v4
765
766 define Device/tl-wr740n-v1
767 $(Device/tplink-4m)
768 DEVICE_TITLE := TP-LINK TL-WR740N/ND v1
769 BOARDNAME := TL-WR741ND
770 DEVICE_PROFILE := TLWR740
771 TPLINK_HWID := 0x07400001
772 endef
773
774 define Device/tl-wr740n-v3
775 $(Device/tl-wr740n-v1)
776 DEVICE_TITLE := TP-LINK TL-WR740N/ND v3
777 TPLINK_HWID := 0x07400003
778 endef
779
780 define Device/tl-wr740n-v4
781 $(Device/tplink-4mlzma)
782 DEVICE_TITLE := TP-LINK TL-WR740N/ND v4
783 BOARDNAME := TL-WR741ND-v4
784 DEVICE_PROFILE := TLWR740
785 TPLINK_HWID := 0x07400004
786 CONSOLE := ttyATH0,115200
787 endef
788
789 define Device/tl-wr740n-v5
790 $(Device/tl-wr740n-v4)
791 DEVICE_TITLE := TP-LINK TL-WR740N/ND v5
792 TPLINK_HWID := 0x07400005
793 endef
794
795 define Device/tl-wr740n-v6
796 $(Device/tplink-4mlzma)
797 DEVICE_TITLE := TP-LINK TL-WR740N/ND v6
798 BOARDNAME := TL-WR740N-v6
799 DEVICE_PROFILE := TLWR740
800 TPLINK_HWID := 0x07400006
801 endef
802 TARGET_DEVICES += tl-wr740n-v1 tl-wr740n-v3 tl-wr740n-v4 tl-wr740n-v5 tl-wr740n-v6
803
804 define Device/tl-wr741nd-v1
805 $(Device/tplink-4m)
806 DEVICE_TITLE := TP-LINK TL-WR741N/ND v1
807 BOARDNAME := TL-WR741ND
808 DEVICE_PROFILE := TLWR741
809 TPLINK_HWID := 0x07410001
810 endef
811
812 define Device/tl-wr741nd-v2
813 $(Device/tl-wr741nd-v1)
814 DEVICE_TITLE := TP-LINK TL-WR741N/ND v2
815 endef
816
817 define Device/tl-wr741nd-v4
818 $(Device/tplink-4mlzma)
819 DEVICE_TITLE := TP-LINK TL-WR741N/ND v4
820 BOARDNAME := TL-WR741ND-v4
821 DEVICE_PROFILE := TLWR741
822 TPLINK_HWID := 0x07410004
823 CONSOLE := ttyATH0,115200
824 endef
825
826 define Device/tl-wr741nd-v5
827 $(Device/tl-wr741nd-v4)
828 DEVICE_TITLE := TP-LINK TL-WR741N/ND v5
829 TPLINK_HWID := 0x07400005
830 endef
831
832 define Device/tl-wr743nd-v1
833 $(Device/tplink-4m)
834 DEVICE_TITLE := TP-LINK TL-WR743N/ND v1
835 BOARDNAME := TL-WR741ND
836 DEVICE_PROFILE := TLWR743
837 TPLINK_HWID := 0x07430001
838 endef
839
840 define Device/tl-wr743nd-v2
841 $(Device/tl-wr741nd-v4)
842 DEVICE_TITLE := TP-LINK TL-WR743N/ND v2
843 DEVICE_PROFILE := TLWR743
844 TPLINK_HWID := 0x07430002
845 endef
846 TARGET_DEVICES += tl-wr741nd-v1 tl-wr741nd-v2 tl-wr741nd-v4 tl-wr741nd-v5 tl-wr743nd-v1 tl-wr743nd-v2
847
848 define Device/tl-wr802n-v1
849 $(Device/tplink-4mlzma)
850 DEVICE_TITLE := TP-LINK TL-WR802N v1
851 BOARDNAME := TL-WR802N-v1
852 DEVICE_PROFILE := TLWR802
853 TPLINK_HWID := 0x08020001
854 TPLINK_HWREV := 1
855 endef
856
857 define Device/tl-wr802n-v2
858 $(Device/tplink-4mlzma)
859 DEVICE_TITLE := TP-LINK TL-WR802N v2
860 BOARDNAME := TL-WR802N-v2
861 DEVICE_PROFILE := TLWR802
862 TPLINK_HWID := 0x08020002
863 TPLINK_HWREV := 2
864 IMAGES += factory-us.bin factory-eu.bin
865 IMAGE/factory-us.bin := append-rootfs | mktplinkfw factory -C US
866 IMAGE/factory-eu.bin := append-rootfs | mktplinkfw factory -C EU
867 endef
868
869 define Device/tl-wr810n-v1
870 $(Device/tplink-8mlzma)
871 DEVICE_TITLE := TP-LINK TL-WR810N v1
872 DEVICE_PACKAGES := kmod-usb-core kmod-usb2
873 BOARDNAME := TL-WR810N
874 DEVICE_PROFILE := TLWR810
875 TPLINK_HWID := 0x08100001
876 endef
877
878 define Device/tl-wr840n-v2
879 $(Device/tplink-4mlzma)
880 DEVICE_TITLE := TP-LINK TL-WR840N v2
881 BOARDNAME := TL-WR840N-v2
882 DEVICE_PROFILE := TLWR840
883 TPLINK_HWID := 0x08400002
884 IMAGES += factory-eu.bin
885 IMAGE/factory-eu.bin := append-rootfs | mktplinkfw factory -C EU
886 endef
887
888 define Device/tl-wr840n-v3
889 $(Device/tl-wr840n-v2)
890 DEVICE_TITLE := TP-LINK TL-WR840N v3
891 BOARDNAME := TL-WR840N-v3
892 TPLINK_HWID := 0x08400003
893 endef
894 TARGET_DEVICES += tl-wr802n-v1 tl-wr802n-v2 tl-wr810n-v1 tl-wr840n-v2 tl-wr840n-v3
895
896 define Device/tl-wr841-v1.5
897 $(Device/tplink-4m)
898 DEVICE_TITLE := TP-LINK TL-WR841N/ND v1.5
899 BOARDNAME := TL-WR841N-v1.5
900 DEVICE_PROFILE := TLWR841
901 TPLINK_HWID := 0x08410002
902 TPLINK_HWREV := 2
903 endef
904
905 define Device/tl-wr841-v3
906 $(Device/tplink-4m)
907 DEVICE_TITLE := TP-LINK TL-WR841N/ND v3
908 BOARDNAME := TL-WR941ND
909 DEVICE_PROFILE := TLWR841
910 TPLINK_HWID := 0x08410003
911 TPLINK_HWREV := 3
912 endef
913
914 define Device/tl-wr841-v5
915 $(Device/tplink-4m)
916 DEVICE_TITLE := TP-LINK TL-WR841N/ND v5
917 BOARDNAME := TL-WR741ND
918 DEVICE_PROFILE := TLWR841
919 TPLINK_HWID := 0x08410005
920 endef
921
922 define Device/tl-wr841-v7
923 $(Device/tplink-4m)
924 DEVICE_TITLE := TP-LINK TL-WR841N/ND v7
925 BOARDNAME := TL-WR841N-v7
926 DEVICE_PROFILE := TLWR841
927 TPLINK_HWID := 0x08410007
928 endef
929
930 define Device/tl-wr841-v8
931 $(Device/tplink-4mlzma)
932 DEVICE_TITLE := TP-LINK TL-WR841N/ND v8
933 BOARDNAME := TL-WR841N-v8
934 DEVICE_PROFILE := TLWR841
935 TPLINK_HWID := 0x08410008
936 endef
937
938 define Device/tl-wr841-v9
939 $(Device/tplink-4mlzma)
940 DEVICE_TITLE := TP-LINK TL-WR841N/ND v9
941 BOARDNAME := TL-WR841N-v9
942 DEVICE_PROFILE := TLWR841
943 TPLINK_HWID := 0x08410009
944 endef
945
946 define Device/tl-wr841-v10
947 $(Device/tl-wr841-v9)
948 DEVICE_TITLE := TP-LINK TL-WR841N/ND v10
949 TPLINK_HWID := 0x08410010
950 endef
951
952 define Device/tl-wr841-v11
953 $(Device/tplink-4mlzma)
954 DEVICE_TITLE := TP-LINK TL-WR841N/ND v11
955 BOARDNAME := TL-WR841N-v11
956 DEVICE_PROFILE := TLWR841
957 TPLINK_HWID := 0x08410011
958 IMAGES += factory-us.bin factory-eu.bin
959 IMAGE/factory-us.bin := append-rootfs | mktplinkfw factory -C US
960 IMAGE/factory-eu.bin := append-rootfs | mktplinkfw factory -C EU
961 endef
962
963 define Device/tl-wr841-v12
964 $(Device/tl-wr841-v11)
965 DEVICE_TITLE := TP-LINK TL-WR841N/ND v12
966 TPLINK_HWID := 0x08410012
967 endef
968 TARGET_DEVICES += tl-wr841-v1.5 tl-wr841-v3 tl-wr841-v5 tl-wr841-v7 tl-wr841-v8 tl-wr841-v9 tl-wr841-v10 tl-wr841-v11 tl-wr841-v12
969
970 define Device/tl-wr842n-v1
971 $(Device/tplink-8m)
972 DEVICE_TITLE := TP-LINK TL-WR842N/ND v1
973 DEVICE_PACKAGES := kmod-usb-core kmod-usb2 kmod-usb-ledtrig-usbport
974 BOARDNAME := TL-MR3420
975 DEVICE_PROFILE := TLWR842
976 TPLINK_HWID := 0x08420001
977 endef
978
979 define Device/tl-wr842n-v2
980 $(Device/tplink-8mlzma)
981 DEVICE_TITLE := TP-LINK TL-WR842N/ND v2
982 DEVICE_PACKAGES := kmod-usb-core kmod-usb2 kmod-usb-ledtrig-usbport
983 BOARDNAME := TL-WR842N-v2
984 DEVICE_PROFILE := TLWR842
985 TPLINK_HWID := 0x8420002
986 endef
987
988 define Device/tl-wr842n-v3
989 $(Device/tplink-16mlzma)
990 DEVICE_TITLE := TP-LINK TL-WR842N/ND v3
991 DEVICE_PACKAGES := kmod-usb-core kmod-usb2 kmod-usb-ledtrig-usbport
992 BOARDNAME := TL-WR842N-v3
993 DEVICE_PROFILE := TLWR842
994 TPLINK_HWID := 0x08420003
995 endef
996
997 define Device/tl-wr843nd-v1
998 $(Device/tplink-4mlzma)
999 DEVICE_TITLE := TP-LINK TL-WR843N/ND v1
1000 BOARDNAME := TL-WR841N-v8
1001 DEVICE_PROFILE := TLWR843
1002 TPLINK_HWID := 0x08430001
1003 endef
1004
1005 define Device/tl-wr847n-v8
1006 $(Device/tplink-4mlzma)
1007 DEVICE_TITLE := TP-LINK TL-WR847N/ND v8
1008 BOARDNAME := TL-WR841N-v8
1009 DEVICE_PROFILE := TLWR841
1010 TPLINK_HWID := 0x08470008
1011 endef
1012 TARGET_DEVICES += tl-wr842n-v1 tl-wr842n-v2 tl-wr842n-v3 tl-wr843nd-v1 tl-wr847n-v8
1013
1014 define Device/tl-wr902ac-v1
1015 DEVICE_TITLE := TP-LINK TL-WR902AC v1
1016 DEVICE_PACKAGES := kmod-usb-core kmod-usb2 kmod-usb-ledtrig-usbport \
1017 kmod-ath10k ath10k-firmware-qca9887 -swconfig -uboot-envtools
1018 BOARDNAME := TL-WR902AC-V1
1019 DEVICE_PROFILE := TLWR902
1020 TPLINK_BOARD_ID := TL-WR902AC-V1
1021 TPLINK_HWID := 0x0
1022 TPLINK_HWREV := 0
1023 TPLINK_HEADER_VERSION := 1
1024 SUPPORTED_DEVICES := tl-wr902ac-v1
1025 IMAGE_SIZE := 7360k
1026 KERNEL := kernel-bin | patch-cmdline | lzma | tplink-v1-header
1027 IMAGES += factory.bin
1028 IMAGE/factory.bin := append-rootfs | tplink-safeloader factory
1029 IMAGE/sysupgrade.bin := append-rootfs | tplink-safeloader sysupgrade | \
1030 append-metadata | check-size $$$$(IMAGE_SIZE)
1031 MTDPARTS := spi0.0:128k(u-boot)ro,7360k(firmware),640k(tplink)ro,64k(art)ro
1032 endef
1033 TARGET_DEVICES += tl-wr902ac-v1
1034
1035 define Device/tl-wr940n-v4
1036 $(Device/tplink-4mlzma)
1037 DEVICE_TITLE := TP-LINK TL-WR940N v4
1038 BOARDNAME := TL-WR940N-v4
1039 DEVICE_PROFILE := TLWR941
1040 TPLINK_HWID := 0x09400004
1041 IMAGES += factory-us.bin factory-eu.bin
1042 IMAGE/factory-us.bin := append-rootfs | mktplinkfw factory -C US
1043 IMAGE/factory-eu.bin := append-rootfs | mktplinkfw factory -C EU
1044 endef
1045
1046 define Device/tl-wr941nd-v2
1047 $(Device/tplink-4m)
1048 DEVICE_TITLE := TP-LINK TL-WR941N/ND v2
1049 BOARDNAME := TL-WR941ND
1050 DEVICE_PROFILE := TLWR941
1051 TPLINK_HWID := 0x09410002
1052 TPLINK_HWREV := 2
1053 endef
1054
1055 define Device/tl-wr941nd-v3
1056 $(Device/tl-wr941nd-v2)
1057 DEVICE_TITLE := TP-LINK TL-WR941N/ND v3
1058 endef
1059
1060 define Device/tl-wr941nd-v4
1061 $(Device/tplink-4m)
1062 DEVICE_TITLE := TP-LINK TL-WR941N/ND v4
1063 BOARDNAME := TL-WR741ND
1064 DEVICE_PROFILE := TLWR941
1065 TPLINK_HWID := 0x09410004
1066 endef
1067
1068 define Device/tl-wr941nd-v5
1069 $(Device/tplink-4mlzma)
1070 DEVICE_TITLE := TP-LINK TL-WR941N/ND v5
1071 BOARDNAME := TL-WR941ND-v5
1072 DEVICE_PROFILE := TLWR941
1073 TPLINK_HWID := 0x09410005
1074 endef
1075
1076 define Device/tl-wr941nd-v6
1077 $(Device/tplink-4mlzma)
1078 DEVICE_TITLE := TP-LINK TL-WR941N/ND v6
1079 BOARDNAME := TL-WR941ND-v6
1080 DEVICE_PROFILE := TLWR941
1081 TPLINK_HWID := 0x09410006
1082 endef
1083
1084 # Chinese version (unlike European) is similar to the TL-WDR3500
1085 define Device/tl-wr941nd-v6-cn
1086 $(Device/tplink-4mlzma)
1087 DEVICE_TITLE := TP-LINK TL-WR941N/ND v6 (CN)
1088 BOARDNAME := TL-WDR3500
1089 DEVICE_PROFILE := TLWR941
1090 TPLINK_HWID := 0x09410006
1091 endef
1092
1093 define Device/tl-wr942n-v1
1094 DEVICE_TITLE := TP-LINK TL-WR942N v1
1095 DEVICE_PACKAGES := kmod-usb-core kmod-usb2 kmod-usb-ledtrig-usbport
1096 BOARDNAME := TL-WR942N-V1
1097 TPLINK_BOARD_ID := TLWR942NV1
1098 DEVICE_PROFILE := TLWR942
1099 IMAGE_SIZE := 14464k
1100 KERNEL := kernel-bin | patch-cmdline | lzma | uImageArcher lzma
1101 IMAGES := sysupgrade.bin factory.bin
1102 IMAGE/sysupgrade.bin := append-rootfs | tplink-safeloader sysupgrade | \
1103 append-metadata | check-size $$$$(IMAGE_SIZE)
1104 IMAGE/factory.bin := append-rootfs | tplink-safeloader factory
1105 MTDPARTS := spi0.0:128k(u-boot)ro,1344k(kernel),13120k(rootfs),64k(product-info)ro,64k(partition-table)ro,256k(oem-config)ro,1344k(oem-vars)ro,64k(ART)ro,14464k@0x20000(firmware)
1106 SUPPORTED_DEVICES := tl-wr942n-v1
1107 endef
1108 TARGET_DEVICES += tl-wr940n-v4 tl-wr941nd-v2 tl-wr941nd-v3 tl-wr941nd-v4 tl-wr941nd-v5 tl-wr941nd-v6 tl-wr941nd-v6-cn tl-wr942n-v1