ramips: fix LAN LED trigger assignment for Xiaomi Router 3 Pro
[openwrt/openwrt.git] / target / linux / ramips / dts / mt7620a_sercomm_na930.dts
1 #include "mt7620a.dtsi"
2
3 #include <dt-bindings/gpio/gpio.h>
4 #include <dt-bindings/input/input.h>
5
6 / {
7 compatible = "sercomm,na930", "ralink,mt7620a-soc";
8 model = "Sercomm NA930";
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 chosen {
18 bootargs = "console=ttyS1,57600";
19 };
20
21 nand {
22 compatible = "mtk,mt7620-nand";
23
24 partitions {
25 compatible = "fixed-partitions";
26 #address-cells = <1>;
27 #size-cells = <1>;
28
29 partition@0 {
30 label = "u-boot";
31 reg = <0x0 0x20000>;
32 read-only;
33 };
34
35 partition@200000 {
36 label = "factory";
37 reg = <0x200000 0x40000>;
38 read-only;
39 };
40
41 partition@240000 {
42 label = "Config";
43 reg = <0x240000 0x400000>;
44 read-only;
45 };
46
47 partition@640000 {
48 compatible = "denx,uimage";
49 label = "firmware";
50 reg = <0x640000 0x1400000>;
51 };
52 };
53 };
54
55 keys {
56 compatible = "gpio-keys";
57
58 reset {
59 label = "reset";
60 gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
61 linux,code = <KEY_RESTART>;
62 };
63
64 zwave {
65 label = "zwave";
66 gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
67 linux,code = <BTN_0>;
68 };
69
70 wps {
71 label = "wps";
72 gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
73 linux,code = <KEY_WPS_BUTTON>;
74 };
75 };
76
77 leds {
78 compatible = "gpio-leds";
79
80 zwave {
81 label = "blue:zwave";
82 gpios = <&gpio2 0 GPIO_ACTIVE_LOW>;
83 };
84
85 status {
86 label = "blue:status";
87 gpios = <&gpio2 26 GPIO_ACTIVE_LOW>;
88 trigger-sources = <&ohci_port1>, <&ehci_port1>;
89 linux,default-trigger = "usbport";
90 };
91
92 service {
93 label = "blue:service";
94 gpios = <&gpio2 28 GPIO_ACTIVE_LOW>;
95 };
96
97 led_power: power {
98 label = "blue:power";
99 gpios = <&gpio2 29 GPIO_ACTIVE_LOW>;
100 };
101 };
102
103 gpio_export {
104 compatible = "gpio-export";
105 #size-cells = <0>;
106
107 telit {
108 gpio-export,name = "telit";
109 gpio-export,output = <1>;
110 gpios = <&gpio0 13 GPIO_ACTIVE_HIGH>;
111 };
112 };
113 };
114
115 &state_default {
116 gpio {
117 groups = "i2c", "rgmii2", "spi", "ephy";
118 function = "gpio";
119 };
120
121 uartf_gpio {
122 groups = "uartf";
123 function = "gpio uartf";
124 };
125 };
126
127 &uart {
128 status = "okay";
129 };
130
131 &gpio2 {
132 status = "okay";
133 };
134
135 &ethernet {
136 pinctrl-names = "default";
137 pinctrl-0 = <&rgmii1_pins &mdio_pins>;
138
139 mediatek,portmap = "llllw";
140
141 port@4 {
142 status = "okay";
143 phy-handle = <&phy4>;
144 phy-mode = "rgmii";
145 };
146
147 port@5 {
148 status = "okay";
149 phy-handle = <&phy5>;
150 phy-mode = "rgmii";
151 };
152
153 mdio-bus {
154 status = "okay";
155
156 phy4: ethernet-phy@4 {
157 reg = <4>;
158 phy-mode = "rgmii";
159 };
160
161 phy5: ethernet-phy@5 {
162 reg = <5>;
163 phy-mode = "rgmii";
164 };
165 };
166 };
167
168 &gsw {
169 mediatek,port4 = "gmac";
170 };
171
172 &ehci {
173 status = "okay";
174 };
175
176 &ohci {
177 status = "okay";
178 };