1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7 #include <dt-bindings/leds/common.h>
10 compatible = "tplink,ec330-g5u-v1", "mediatek,mt7621-soc";
11 model = "TP-Link EC330-G5u v1";
14 label-mac-device = &gmac0;
16 led-boot = &led_power;
17 led-failsafe = &led_power;
18 led-running = &led_power;
19 led-upgrade = &led_power;
23 bootargs = "console=ttyS0,115200";
27 compatible = "gpio-leds";
30 color = <LED_COLOR_ID_BLUE>;
31 function = LED_FUNCTION_USB;
32 function-enumerator = <0>;
33 gpios = <&gpio 0 GPIO_ACTIVE_LOW>;
34 trigger-sources = <&xhci_ehci_port1>;
35 linux,default-trigger = "usbport";
40 color = <LED_COLOR_ID_BLUE>;
41 function = LED_FUNCTION_WPS;
42 function-enumerator = <0>;
43 gpios = <&gpio 5 GPIO_ACTIVE_LOW>;
47 label = "blue:ethernet";
48 color = <LED_COLOR_ID_BLUE>;
49 function = LED_FUNCTION_LAN;
50 function-enumerator = <0>;
51 gpios = <&gpio 9 GPIO_ACTIVE_LOW>;
55 label = "amber:internet";
56 color = <LED_COLOR_ID_AMBER>;
57 function = LED_FUNCTION_WAN;
58 function-enumerator = <0>;
59 gpios = <&gpio 13 GPIO_ACTIVE_LOW>;
63 label = "blue:internet";
64 color = <LED_COLOR_ID_BLUE>;
65 function = LED_FUNCTION_WAN;
66 function-enumerator = <1>;
67 gpios = <&gpio 14 GPIO_ACTIVE_LOW>;
71 label = "blue:wireless_5g";
72 color = <LED_COLOR_ID_BLUE>;
73 function = LED_FUNCTION_WLAN;
74 function-enumerator = <0>;
75 gpios = <&gpio 15 GPIO_ACTIVE_LOW>;
76 linux,default-trigger = "phy1tpt";
80 label = "blue:wireless_2g";
81 color = <LED_COLOR_ID_BLUE>;
82 function = LED_FUNCTION_WLAN;
83 function-enumerator = <1>;
84 gpios = <&gpio 16 GPIO_ACTIVE_LOW>;
85 linux,default-trigger = "phy0tpt";
90 color = <LED_COLOR_ID_BLUE>;
91 function = LED_FUNCTION_STATUS;
92 function-enumerator = <0>;
93 gpios = <&gpio 18 GPIO_ACTIVE_LOW>;
98 compatible = "gpio-keys";
102 gpios = <&gpio 4 GPIO_ACTIVE_LOW>;
103 debounce-interval = <60>;
104 linux,code = <KEY_LIGHTS_TOGGLE>;
108 label = "wifi on/off";
109 gpios = <&gpio 7 GPIO_ACTIVE_LOW>;
110 debounce-interval = <60>;
111 linux,code = <KEY_RFKILL>;
116 gpios = <&gpio 8 GPIO_ACTIVE_LOW>;
117 debounce-interval = <60>;
118 linux,code = <KEY_RESTART>;
123 gpios = <&gpio 10 GPIO_ACTIVE_LOW>;
124 debounce-interval = <60>;
125 linux,code = <KEY_WPS_BUTTON>;
130 compatible = "gpio-export";
133 gpio-export,name = "led-light";
134 gpio-export,output = <0>;
135 gpios = <&gpio 3 GPIO_ACTIVE_LOW>;
140 compatible = "mtd-concat";
141 devices = <&ubiconcat0 &ubiconcat1>;
144 compatible = "fixed-partitions";
145 #address-cells = <1>;
150 reg = <0x0 0x3c00000>;
160 compatible = "fixed-partitions";
161 #address-cells = <1>;
166 reg = <0x0 0x400000>;
169 compatible = "fixed-partitions";
170 #address-cells = <1>;
174 label = "u-boot-first";
180 label = "u-boot-main";
181 reg = <0x20000 0x40000>;
186 label = "u-boot-main-reserve";
187 reg = <0x60000 0x40000>;
194 reg = <0x400000 0x3000000>;
196 compatible = "fixed-partitions";
197 #address-cells = <1>;
202 reg = <0x0 0x400000>;
205 ubiconcat0: partition@400000 {
207 reg = <0x400000 0x2c00000>;
213 reg = <0x3400000 0x3000000>;
217 ubiconcat1: partition@6400000 {
219 reg = <0x6400000 0x1000000>;
223 label = "u-boot-env";
224 reg = <0x7400000 0x400000>;
227 factory: partition@7800000 {
229 reg = <0x7800000 0x400000>;
233 compatible = "fixed-layout";
234 #address-cells = <1>;
237 eeprom_factory_8000: eeprom@8000 {
238 reg = <0x8000 0x4da8>;
241 eeprom_factory_14000: eeprom@14000 {
242 reg = <0x14000 0x4da8>;
245 macaddr_factory_165: macaddr@165 {
246 compatible = "mac-base";
248 #nvmem-cell-cells = <1>;
253 partition@0_wholeflash {
254 label = "wholeflash";
255 reg = <0x0 0x7f80000>;
267 compatible = "mediatek,mt76";
268 reg = <0x0000 0 0 0 0>;
269 ieee80211-freq-limit = <2400000 2500000>;
270 nvmem-cells = <&eeprom_factory_8000>, <&macaddr_factory_165 0>;
271 nvmem-cell-names = "eeprom", "mac-address";
277 compatible = "mediatek,mt76";
278 reg = <0x0000 0 0 0 0>;
279 ieee80211-freq-limit = <5000000 6000000>;
280 nvmem-cells = <&eeprom_factory_14000>, <&macaddr_factory_165 2>;
281 nvmem-cell-names = "eeprom", "mac-address";
286 nvmem-cells = <&macaddr_factory_165 0>;
287 nvmem-cell-names = "mac-address";
293 phy-handle = <ðphy0>;
295 nvmem-cells = <&macaddr_factory_165 1>;
296 nvmem-cell-names = "mac-address";
300 ethphy0: ethernet-phy@0 {
331 groups = "i2c", "jtag", "uart2", "uart3", "wdt";