ath79: add WNDR3700 and WNDR3700v2
authorHannu Nyman <hannu.nyman@iki.fi>
Sat, 11 Aug 2018 22:18:53 +0000 (01:18 +0300)
committerMathias Kresin <dev@kresin.me>
Mon, 13 Aug 2018 06:37:19 +0000 (08:37 +0200)
Add support for WNDR3700 and WNDR3700v2.

They share most things with WNDR3800.
Only device IDs and partition structure needs to be set.

Note: WNDR3700 (v1) has no NETGEAR_HW_ID, but has
      also the NA version of the factory image.

Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
target/linux/ath79/base-files/etc/board.d/02_network
target/linux/ath79/dts/ar7161_netgear_wndr3700.dts [new file with mode: 0644]
target/linux/ath79/dts/ar7161_netgear_wndr3700v2.dts [new file with mode: 0644]
target/linux/ath79/image/generic.mk

index fe2d5859d32fc9ed7c7cdd425886c3eb1f8099b6..9e315ee866eef1bad029d67f8a0798a40436d3ff 100755 (executable)
@@ -51,6 +51,8 @@ ath79_setup_interfaces()
                ucidef_add_switch "switch0" \
                        "0@eth0" "1:lan" "2:lan" "3:lan" "4:lan" "5:wan"
                ;;
+       netgear,wndr3700|\
+       netgear,wndr3700v2|\
        netgear,wndr3800)
                ucidef_set_interfaces_lan_wan "eth0" "eth1"
                ucidef_add_switch "switch0" \
diff --git a/target/linux/ath79/dts/ar7161_netgear_wndr3700.dts b/target/linux/ath79/dts/ar7161_netgear_wndr3700.dts
new file mode 100644 (file)
index 0000000..4cfe59a
--- /dev/null
@@ -0,0 +1,34 @@
+// SPDX-License-Identifier: GPL-2.0-or-later OR MIT
+/dts-v1/;
+
+#include "ar7161_netgear_wndr3700.dtsi"
+
+/ {
+       compatible = "netgear,wndr3700", "qca,ar7161";
+       model = "Netgear WNDR3700";
+};
+
+&partitions {
+       partition@0 {
+               label = "u-boot";
+               reg = <0x000000 0x050000>;
+               read-only;
+       };
+
+       partition@50000 {
+               label = "u-boot-env";
+               reg = <0x050000 0x020000>;
+               read-only;
+       };
+
+       partition@70000 {
+               label = "firmware";
+               reg = <0x070000 0x780000>;
+       };
+
+       art: partition@7f0000 {
+               label = "art";
+               reg = <0x7f0000 0x010000>;
+               read-only;
+       };
+};
diff --git a/target/linux/ath79/dts/ar7161_netgear_wndr3700v2.dts b/target/linux/ath79/dts/ar7161_netgear_wndr3700v2.dts
new file mode 100644 (file)
index 0000000..1eb376e
--- /dev/null
@@ -0,0 +1,34 @@
+// SPDX-License-Identifier: GPL-2.0-or-later OR MIT
+/dts-v1/;
+
+#include "ar7161_netgear_wndr3700.dtsi"
+
+/ {
+       compatible = "netgear,wndr3700v2", "qca,ar7161";
+       model = "Netgear WNDR3700v2";
+};
+
+&partitions {
+       partition@0 {
+               label = "u-boot";
+               reg = <0x000000 0x050000>;
+               read-only;
+       };
+
+       partition@50000 {
+               label = "u-boot-env";
+               reg = <0x050000 0x020000>;
+               read-only;
+       };
+
+       partition@70000 {
+               label = "firmware";
+               reg = <0x070000 0xf80000>;
+       };
+
+       art: partition@ff0000 {
+               label = "art";
+               reg = <0xff0000 0x010000>;
+               read-only;
+       };
+};
index 6aaee7015a0dc28a51362ade1e681eff327556e1..ddde8beee83d57b20426d7d0c5397ecde952b887 100644 (file)
@@ -144,6 +144,29 @@ define Device/netgear_wndr3x00
   DEVICE_PACKAGES := kmod-usb-core kmod-usb-ohci kmod-usb2 kmod-usb-ledtrig-usbport kmod-leds-reset
 endef
 
+define Device/netgear_wndr3700
+  $(Device/netgear_wndr3x00)
+  DEVICE_TITLE := NETGEAR WNDR3700
+  NETGEAR_KERNEL_MAGIC := 0x33373030
+  NETGEAR_BOARD_ID := WNDR3700
+  IMAGE_SIZE := 7680k
+  IMAGES += factory-NA.img
+  IMAGE/factory-NA.img := $$(IMAGE/default) | netgear-dni NA | check-size $$$$(IMAGE_SIZE)
+  SUPPORTED_DEVICES += wndr3700
+endef
+TARGET_DEVICES += netgear_wndr3700
+
+define Device/netgear_wndr3700v2
+  $(Device/netgear_wndr3x00)
+  DEVICE_TITLE := NETGEAR WNDR3700v2
+  NETGEAR_KERNEL_MAGIC := 0x33373031
+  NETGEAR_BOARD_ID := WNDR3700v2
+  NETGEAR_HW_ID := 29763654+16+64
+  IMAGE_SIZE := 15872k
+  SUPPORTED_DEVICES += wndr3700v2
+endef
+TARGET_DEVICES += netgear_wndr3700v2
+
 define Device/netgear_wndr3800
   $(Device/netgear_wndr3x00)
   DEVICE_TITLE := NETGEAR WNDR3800