ramips: sercomm s1500: enable wlan LEDs activity blinking
[openwrt/openwrt.git] / target / linux / ramips / dts / mt7628an_tplink_tl-wr902ac-v4.dts
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2
3 #include "mt7628an_tplink_8m.dtsi"
4 #include <dt-bindings/leds/common.h>
5
6 / {
7 compatible = "tplink,tl-wr902ac-v4", "mediatek,mt7628an-soc";
8 model = "TP-Link TL-WR902AC v4";
9
10 aliases {
11 led-boot = &led_power;
12 led-failsafe = &led_power;
13 led-running = &led_power;
14 led-upgrade = &led_power;
15 };
16
17 keys {
18 compatible = "gpio-keys";
19
20 button-reset {
21 label = "reset";
22 gpios = <&gpio 38 GPIO_ACTIVE_LOW>;
23 linux,code = <KEY_RESTART>;
24 };
25
26 button-sw1 {
27 label = "sw1";
28 gpios = <&gpio 2 GPIO_ACTIVE_LOW>;
29 linux,code = <BTN_0>;
30 };
31
32 button-sw2 {
33 label = "sw2";
34 gpios = <&gpio 3 GPIO_ACTIVE_LOW>;
35 linux,code = <BTN_1>;
36 };
37
38 button-wps {
39 label = "wps";
40 gpios = <&gpio 41 GPIO_ACTIVE_LOW>;
41 linux,code = <KEY_WPS_BUTTON>;
42 };
43 };
44
45 leds {
46 compatible = "gpio-leds";
47
48 led_power: led-0 {
49 color = <LED_COLOR_ID_GREEN>;
50 function = LED_FUNCTION_POWER;
51 gpios = <&gpio 46 GPIO_ACTIVE_LOW>;
52 };
53
54 led-1 {
55 color = <LED_COLOR_ID_GREEN>;
56 function = LED_FUNCTION_USB;
57 gpios = <&gpio 43 GPIO_ACTIVE_LOW>;
58 trigger-sources = <&ohci_port1>, <&ehci_port1>;
59 linux,default-trigger = "usbport";
60 };
61
62 led-2 {
63 color = <LED_COLOR_ID_GREEN>;
64 function = LED_FUNCTION_WAN;
65 gpios = <&gpio 39 GPIO_ACTIVE_LOW>;
66 };
67
68 led-3 {
69 color = <LED_COLOR_ID_GREEN>;
70 function = LED_FUNCTION_WLAN;
71 gpios = <&gpio 44 GPIO_ACTIVE_LOW>;
72 linux,default-trigger = "phy0tpt";
73 };
74
75 led-4 {
76 function = LED_FUNCTION_WPS;
77 color = <LED_COLOR_ID_GREEN>;
78 gpios = <&gpio 4 GPIO_ACTIVE_LOW>;
79 };
80 };
81 };
82
83 &eeprom_factory_28000 {
84 /* tl-wr902ac-v4 has different eeprom size '0x4da8' for MT7613 */
85 reg = <0x28000 0x4da8>;
86 };
87
88 &pcie {
89 status = "okay";
90 };
91
92 &pcie0 {
93 wifi@0,0 {
94 compatible = "mediatek,mt76";
95 reg = <0x0000 0 0 0 0>;
96 ieee80211-freq-limit = <5000000 6000000>;
97 nvmem-cells = <&eeprom_factory_28000>, <&macaddr_factory_f100 (-1)>;
98 nvmem-cell-names = "eeprom", "mac-address";
99 };
100 };
101
102 &state_default {
103 gpio {
104 groups = "i2c", "i2s", "p0led_an", "p2led_an", "p4led_an", "uart1", "wdt", "wled_an";
105 function = "gpio";
106 };
107 };
108
109 &wmac {
110 status = "okay";
111 nvmem-cells = <&eeprom_factory_28000>, <&macaddr_factory_f100 0>;
112 nvmem-cell-names = "eeprom", "mac-address";
113 };