[OpenWrt-Devel] [PATCH 3/4] ath79: use separate file for generic D-Link images
Stijn Tintel
stijn at linux-ipv6.be
Mon Jun 8 05:36:30 EDT 2020
Move the generic D-Link image definitions to a separate file, as is done
for several other vendors.
Signed-off-by: Stijn Tintel <stijn at linux-ipv6.be>
---
target/linux/ath79/image/Makefile | 1 +
target/linux/ath79/image/generic-dlink.mk | 114 +++++++++++++++++++++
target/linux/ath79/image/generic.mk | 115 ----------------------
3 files changed, 115 insertions(+), 115 deletions(-)
create mode 100644 target/linux/ath79/image/generic-dlink.mk
diff --git a/target/linux/ath79/image/Makefile b/target/linux/ath79/image/Makefile
index 529baf8f57..6a286d3f1f 100644
--- a/target/linux/ath79/image/Makefile
+++ b/target/linux/ath79/image/Makefile
@@ -70,6 +70,7 @@ endef
ifeq ($(SUBTARGET),generic)
include ./generic.mk
+include ./generic-dlink.mk
include ./generic-tp-link.mk
include ./generic-ubnt.mk
endif
diff --git a/target/linux/ath79/image/generic-dlink.mk b/target/linux/ath79/image/generic-dlink.mk
new file mode 100644
index 0000000000..96cb015a09
--- /dev/null
+++ b/target/linux/ath79/image/generic-dlink.mk
@@ -0,0 +1,114 @@
+define Device/dlink_dir-505
+ SOC := ar9330
+ DEVICE_VENDOR := D-Link
+ DEVICE_MODEL := DIR-505
+ IMAGE_SIZE := 7680k
+ DEVICE_PACKAGES := kmod-usb2
+ SUPPORTED_DEVICES += dir-505-a1
+endef
+TARGET_DEVICES += dlink_dir-505
+
+define Device/dlink_dir-825-b1
+ SOC := ar7161
+ DEVICE_VENDOR := D-Link
+ DEVICE_MODEL := DIR-825
+ DEVICE_VARIANT := B1
+ IMAGE_SIZE := 6208k
+ IMAGE/sysupgrade.bin := append-kernel | append-rootfs | pad-rootfs | \
+ append-metadata | check-size
+ DEVICE_PACKAGES := kmod-usb-ohci kmod-usb2 kmod-usb-ledtrig-usbport \
+ kmod-leds-reset kmod-owl-loader
+ SUPPORTED_DEVICES += dir-825-b1
+endef
+TARGET_DEVICES += dlink_dir-825-b1
+
+define Device/dlink_dir-825-c1
+ SOC := ar9344
+ DEVICE_VENDOR := D-Link
+ DEVICE_MODEL := DIR-825
+ DEVICE_VARIANT := C1
+ DEVICE_PACKAGES := kmod-usb2 kmod-usb-ledtrig-usbport kmod-leds-reset \
+ kmod-owl-loader
+ SUPPORTED_DEVICES += dir-825-c1
+ IMAGE_SIZE := 15936k
+ IMAGES := factory.bin sysupgrade.bin
+ IMAGE/default := append-kernel | pad-to $$$$(BLOCKSIZE) | append-rootfs | \
+ 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
+endef
+TARGET_DEVICES += dlink_dir-825-c1
+
+define Device/dlink_dir-835-a1
+ SOC := ar9344
+ DEVICE_VENDOR := D-Link
+ DEVICE_MODEL := DIR-835
+ DEVICE_VARIANT := A1
+ DEVICE_PACKAGES := kmod-usb2 kmod-leds-reset kmod-owl-loader
+ SUPPORTED_DEVICES += dir-835-a1
+ IMAGE_SIZE := 15936k
+ IMAGES := factory.bin sysupgrade.bin
+ IMAGE/default := append-kernel | pad-to $$$$(BLOCKSIZE) | append-rootfs | \
+ 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
+endef
+TARGET_DEVICES += dlink_dir-835-a1
+
+define Device/dlink_dir-842-c
+ SOC := qca9563
+ DEVICE_VENDOR := D-Link
+ DEVICE_MODEL := DIR-842
+ KERNEL := kernel-bin | append-dtb | relocate-kernel | lzma
+ KERNEL_INITRAMFS := $$(KERNEL) | seama
+ IMAGES += factory.bin
+ SEAMA_MTDBLOCK := 5
+ SEAMA_SIGNATURE := wrgac65_dlink.2015_dir842
+ # 64 bytes offset:
+ # - 28 bytes seama_header
+ # - 36 bytes of META data (4-bytes aligned)
+ IMAGE/default := append-kernel | uImage lzma | \
+ 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 | check-size
+ IMAGE_SIZE := 15680k
+endef
+
+define Device/dlink_dir-842-c1
+ $(Device/dlink_dir-842-c)
+ DEVICE_VARIANT := C1
+ DEVICE_PACKAGES := kmod-ath10k-ct ath10k-firmware-qca9888-ct
+endef
+TARGET_DEVICES += dlink_dir-842-c1
+
+define Device/dlink_dir-842-c2
+ $(Device/dlink_dir-842-c)
+ DEVICE_VARIANT := C2
+ DEVICE_PACKAGES := kmod-usb2 kmod-ath10k-ct ath10k-firmware-qca9888-ct
+endef
+TARGET_DEVICES += dlink_dir-842-c2
+
+define Device/dlink_dir-842-c3
+ $(Device/dlink_dir-842-c)
+ DEVICE_VARIANT := C3
+ DEVICE_PACKAGES := kmod-ath10k-ct ath10k-firmware-qca9888-ct
+endef
+TARGET_DEVICES += dlink_dir-842-c3
+
+define Device/dlink_dir-859-a1
+ $(Device/seama)
+ SOC := qca9563
+ DEVICE_VENDOR := D-Link
+ DEVICE_MODEL := DIR-859
+ DEVICE_VARIANT := A1
+ IMAGE_SIZE := 15872k
+ DEVICE_PACKAGES := kmod-usb2 kmod-ath10k-ct-smallbuffers ath10k-firmware-qca988x-ct
+ SEAMA_SIGNATURE := wrgac37_dlink.2013gui_dir859
+endef
+TARGET_DEVICES += dlink_dir-859-a1
diff --git a/target/linux/ath79/image/generic.mk b/target/linux/ath79/image/generic.mk
index 45dfc6bdad..cba2f51697 100644
--- a/target/linux/ath79/image/generic.mk
+++ b/target/linux/ath79/image/generic.mk
@@ -458,121 +458,6 @@ define Device/devolo_magic-2-wifi
endef
TARGET_DEVICES += devolo_magic-2-wifi
-define Device/dlink_dir-505
- SOC := ar9330
- DEVICE_VENDOR := D-Link
- DEVICE_MODEL := DIR-505
- IMAGE_SIZE := 7680k
- DEVICE_PACKAGES := kmod-usb2
- SUPPORTED_DEVICES += dir-505-a1
-endef
-TARGET_DEVICES += dlink_dir-505
-
-define Device/dlink_dir-825-b1
- SOC := ar7161
- DEVICE_VENDOR := D-Link
- DEVICE_MODEL := DIR-825
- DEVICE_VARIANT := B1
- IMAGE_SIZE := 6208k
- IMAGE/sysupgrade.bin := append-kernel | append-rootfs | pad-rootfs | \
- append-metadata | check-size
- DEVICE_PACKAGES := kmod-usb-ohci kmod-usb2 kmod-usb-ledtrig-usbport \
- kmod-leds-reset kmod-owl-loader
- SUPPORTED_DEVICES += dir-825-b1
-endef
-TARGET_DEVICES += dlink_dir-825-b1
-
-define Device/dlink_dir-825-c1
- SOC := ar9344
- DEVICE_VENDOR := D-Link
- DEVICE_MODEL := DIR-825
- DEVICE_VARIANT := C1
- DEVICE_PACKAGES := kmod-usb2 kmod-usb-ledtrig-usbport kmod-leds-reset \
- kmod-owl-loader
- SUPPORTED_DEVICES += dir-825-c1
- IMAGE_SIZE := 15936k
- IMAGES := factory.bin sysupgrade.bin
- IMAGE/default := append-kernel | pad-to $$$$(BLOCKSIZE) | append-rootfs | \
- 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
-endef
-TARGET_DEVICES += dlink_dir-825-c1
-
-define Device/dlink_dir-835-a1
- SOC := ar9344
- DEVICE_VENDOR := D-Link
- DEVICE_MODEL := DIR-835
- DEVICE_VARIANT := A1
- DEVICE_PACKAGES := kmod-usb2 kmod-leds-reset kmod-owl-loader
- SUPPORTED_DEVICES += dir-835-a1
- IMAGE_SIZE := 15936k
- IMAGES := factory.bin sysupgrade.bin
- IMAGE/default := append-kernel | pad-to $$$$(BLOCKSIZE) | append-rootfs | \
- 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
-endef
-TARGET_DEVICES += dlink_dir-835-a1
-
-define Device/dlink_dir-842-c
- SOC := qca9563
- DEVICE_VENDOR := D-Link
- DEVICE_MODEL := DIR-842
- KERNEL := kernel-bin | append-dtb | relocate-kernel | lzma
- KERNEL_INITRAMFS := $$(KERNEL) | seama
- IMAGES += factory.bin
- SEAMA_MTDBLOCK := 5
- SEAMA_SIGNATURE := wrgac65_dlink.2015_dir842
- # 64 bytes offset:
- # - 28 bytes seama_header
- # - 36 bytes of META data (4-bytes aligned)
- IMAGE/default := append-kernel | uImage lzma | \
- 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 | check-size
- IMAGE_SIZE := 15680k
-endef
-
-define Device/dlink_dir-842-c1
- $(Device/dlink_dir-842-c)
- DEVICE_VARIANT := C1
- DEVICE_PACKAGES := kmod-ath10k-ct ath10k-firmware-qca9888-ct
-endef
-TARGET_DEVICES += dlink_dir-842-c1
-
-define Device/dlink_dir-842-c2
- $(Device/dlink_dir-842-c)
- DEVICE_VARIANT := C2
- DEVICE_PACKAGES := kmod-usb2 kmod-ath10k-ct ath10k-firmware-qca9888-ct
-endef
-TARGET_DEVICES += dlink_dir-842-c2
-
-define Device/dlink_dir-842-c3
- $(Device/dlink_dir-842-c)
- DEVICE_VARIANT := C3
- DEVICE_PACKAGES := kmod-ath10k-ct ath10k-firmware-qca9888-ct
-endef
-TARGET_DEVICES += dlink_dir-842-c3
-
-define Device/dlink_dir-859-a1
- $(Device/seama)
- SOC := qca9563
- DEVICE_VENDOR := D-Link
- DEVICE_MODEL := DIR-859
- DEVICE_VARIANT := A1
- IMAGE_SIZE := 15872k
- DEVICE_PACKAGES := kmod-usb2 kmod-ath10k-ct-smallbuffers ath10k-firmware-qca988x-ct
- SEAMA_SIGNATURE := wrgac37_dlink.2013gui_dir859
-endef
-TARGET_DEVICES += dlink_dir-859-a1
-
define Device/elecom_wrc-1750ghbk2-i
SOC := qca9563
DEVICE_VENDOR := ELECOM
--
2.26.2
_______________________________________________
openwrt-devel mailing list
openwrt-devel at lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel
More information about the openwrt-devel
mailing list