aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/lantiq/image
diff options
context:
space:
mode:
authorPiotr Dymacz <pepe2k@gmail.com>2017-06-23 23:07:10 +0200
committerPiotr Dymacz <pepe2k@gmail.com>2017-06-29 10:37:36 +0200
commit5b7f59225118a3553af5e9d485e2445f28444fb9 (patch)
tree9b7dddb8a8120b07e8e8db9152d923279beb0a97 /target/linux/lantiq/image
parent7d6c63d875421fc1f66833ba0e690914ea28f1a3 (diff)
downloadupstream-5b7f59225118a3553af5e9d485e2445f28444fb9.tar.gz
upstream-5b7f59225118a3553af5e9d485e2445f28444fb9.tar.bz2
upstream-5b7f59225118a3553af5e9d485e2445f28444fb9.zip
build: move mktplinkfw2 related commands to image-commands.mk
There are already two targets (lantiq, ramips) which use mktplinkfw2 tool for creating images. This de-duplicates code, introduces two new build commands: tplink-v2-header, tplink-v2-image and makes use of them in place of old, (sub)target specific ones. Signed-off-by: Piotr Dymacz <pepe2k@gmail.com>
Diffstat (limited to 'target/linux/lantiq/image')
-rw-r--r--target/linux/lantiq/image/tp-link.mk25
1 files changed, 8 insertions, 17 deletions
diff --git a/target/linux/lantiq/image/tp-link.mk b/target/linux/lantiq/image/tp-link.mk
index 49c4bc10e1..976184175a 100644
--- a/target/linux/lantiq/image/tp-link.mk
+++ b/target/linux/lantiq/image/tp-link.mk
@@ -1,27 +1,18 @@
-define Build/tplink-fw
- mktplinkfw2 -c -B $(BOARD_ID) -s \
- -k $@ -o $@.new
- mv $@.new $@
-endef
-
-define Build/mktplinkfw2
- mktplinkfw2 -B $(BOARD_ID) -s -a 0x4 -j \
- -k $(IMAGE_KERNEL) -r $(IMAGE_ROOTFS) \
- -o $@
-endef
-DEVICE_VARS += BOARD_ID
+DEVICE_VARS += TPLINK_BOARD_ID
define Device/lantiqTpLink
KERNEL := kernel-bin | append-dtb | lzma
- KERNEL_INITRAMFS := kernel-bin | append-dtb | lzma | tplink-fw
+ KERNEL_INITRAMFS := kernel-bin | append-dtb | lzma | \
+ tplink-v2-header -s -V "ver. 1.0"
IMAGES := sysupgrade.bin
- IMAGE/sysupgrade.bin := mktplinkfw2 | append-metadata | check-size $$$$(IMAGE_SIZE)
+ IMAGE/sysupgrade.bin := tplink-v2-image -s -V "ver. 1.0" | \
+ append-metadata | check-size $$$$(IMAGE_SIZE)
endef
define Device/TDW8970
$(Device/lantiqTpLink)
DEVICE_PROFILE := TDW8970
- BOARD_ID := TD-W8970v1
+ TPLINK_BOARD_ID := TD-W8970v1
IMAGE_SIZE := 7680k
DEVICE_TITLE := TP-LINK TD-W8970
DEVICE_PACKAGES:= kmod-ath9k wpad-mini kmod-usb-dwc2 kmod-usb-ledtrig-usbport
@@ -30,7 +21,7 @@ endef
define Device/TDW8980
$(Device/lantiqTpLink)
DEVICE_PROFILE := TDW8980
- BOARD_ID := TD-W8980v1
+ TPLINK_BOARD_ID := TD-W8980v1
IMAGE_SIZE := 7680k
DEVICE_TITLE := TP-LINK TD-W8980
DEVICE_PACKAGES:= kmod-ath9k kmod-owl-loader wpad-mini kmod-usb-dwc2 kmod-usb-ledtrig-usbport
@@ -39,7 +30,7 @@ endef
define Device/VR200v
$(Device/lantiqTpLink)
DEVICE_PROFILE := VR200v
- BOARD_ID := ArcherVR200V
+ TPLINK_BOARD_ID := ArcherVR200V
IMAGE_SIZE := 15808k
DEVICE_TITLE := TP-LINK Archer VR200v
DEVICE_PACKAGES:= kmod-usb-dwc2 kmod-usb-ledtrig-usbport