1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
3 #include "qca953x.dtsi"
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7 #include <dt-bindings/leds/common.h>
10 compatible = "tplink,tl-mr3420-v3", "qca,qca9531";
11 model = "TP-Link TL-MR3420 v3";
14 led-boot = &led_system;
15 led-failsafe = &led_system;
16 led-running = &led_system;
17 led-upgrade = &led_system;
18 label-mac-device = &wmac;
23 compatible = "spi-gpio";
27 sck-gpios = <&gpio 15 GPIO_ACTIVE_HIGH>;
28 mosi-gpios = <&gpio 16 GPIO_ACTIVE_HIGH>;
29 cs-gpios = <&gpio 13 GPIO_ACTIVE_HIGH>;
30 num-chipselects = <1>;
32 led_gpio: led_gpio@0 {
33 compatible = "fairchild,74hc595";
37 registers-number = <1>;
38 spi-max-frequency = <10000000>;
43 compatible = "gpio-export";
45 gpio_shift_register_oe {
46 gpio-export,name = "tp-link:oe:sr";
47 gpio-export,output = <0>;
48 gpios = <&gpio 11 GPIO_ACTIVE_LOW>;
51 gpio_shift_register_reset {
52 gpio-export,name = "tp-link:reset:sr";
53 gpio-export,output = <1>;
54 gpios = <&gpio 14 GPIO_ACTIVE_LOW>;
59 compatible = "gpio-leds";
62 label = "green:system";
63 gpios = <&gpio 1 GPIO_ACTIVE_LOW>;
69 gpios = <&led_gpio 0 GPIO_ACTIVE_LOW>;
74 gpios = <&led_gpio 1 GPIO_ACTIVE_LOW>;
79 gpios = <&led_gpio 2 GPIO_ACTIVE_LOW>;
84 gpios = <&led_gpio 3 GPIO_ACTIVE_LOW>;
88 function = LED_FUNCTION_WAN;
89 color = <LED_COLOR_ID_GREEN>;
90 gpios = <&led_gpio 4 GPIO_ACTIVE_LOW>;
94 function = LED_FUNCTION_WAN;
95 color = <LED_COLOR_ID_ORANGE>;
96 gpios = <&led_gpio 5 GPIO_ACTIVE_LOW>;
100 function = LED_FUNCTION_WLAN;
101 color = <LED_COLOR_ID_GREEN>;
102 gpios = <&led_gpio 6 GPIO_ACTIVE_LOW>;
103 linux,default-trigger = "phy0tpt";
107 function = LED_FUNCTION_USB;
108 color = <LED_COLOR_ID_GREEN>;
109 gpios = <&led_gpio 7 GPIO_ACTIVE_LOW>;
110 trigger-sources = <&hub_port0>;
111 linux,default-trigger = "usbport";
116 gpios = <&gpio 3 GPIO_ACTIVE_LOW>;
121 compatible = "gpio-keys";
124 label = "Reset button";
125 linux,code = <KEY_RESTART>;
126 gpios = <&gpio 12 GPIO_ACTIVE_LOW>;
127 debounce-interval = <60>;
131 label = "RF kill button";
132 linux,code = <KEY_RFKILL>;
133 gpios = <&gpio 17 GPIO_ACTIVE_LOW>;
134 debounce-interval = <60>;
144 compatible = "jedec,spi-nor";
146 spi-max-frequency = <25000000>;
149 compatible = "fixed-partitions";
150 #address-cells = <1>;
155 reg = <0x000000 0x020000>;
159 compatible = "fixed-layout";
160 #address-cells = <1>;
163 macaddr_uboot_1fc00: macaddr@1fc00 {
164 compatible = "mac-base";
166 #nvmem-cell-cells = <1>;
172 compatible = "tplink,firmware";
174 reg = <0x020000 0x3d0000>;
177 art: partition@3f0000 {
179 reg = <0x3f0000 0x010000>;
189 phy-handle = <&swphy4>;
191 nvmem-cells = <&macaddr_uboot_1fc00 1>;
192 nvmem-cell-names = "mac-address";
196 nvmem-cells = <&macaddr_uboot_1fc00 0>;
197 nvmem-cell-names = "mac-address";
203 mtd-cal-data = <&art 0x1000>;
204 nvmem-cells = <&macaddr_uboot_1fc00 0>;
205 nvmem-cell-names = "mac-address";