ramips: fix LAN LED trigger assignment for Xiaomi Router 3 Pro
[openwrt/openwrt.git] / target / linux / ramips / dts / mt7620n_dlink_dwr-921-c1.dts
1 #include "mt7620n.dtsi"
2
3 #include <dt-bindings/gpio/gpio.h>
4 #include <dt-bindings/input/input.h>
5
6 / {
7 compatible = "dlink,dwr-921-c1", "ralink,mt7620n-soc";
8 model = "D-Link DWR-921 C1";
9
10 aliases {
11 led-boot = &led_sstrenghg;
12 led-failsafe = &led_sstrenghg;
13 };
14
15 keys {
16 compatible = "gpio-keys";
17
18 wps {
19 label = "wps";
20 gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
21 linux,code = <KEY_WPS_BUTTON>;
22 };
23
24 reset {
25 label = "reset";
26 gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
27 linux,code = <KEY_RESTART>;
28 };
29 };
30
31 leds {
32 compatible = "gpio-leds";
33
34 sms {
35 label = "green:sms";
36 gpios = <&gpio1 14 GPIO_ACTIVE_LOW>;
37 };
38
39 lan {
40 label = "green:lan";
41 gpios = <&gpio1 15 GPIO_ACTIVE_HIGH>;
42 };
43
44 led_sstrenghg: sstrengthg {
45 label = "green:sigstrength";
46 gpios = <&gpio2 0 GPIO_ACTIVE_LOW>;
47 };
48
49 sstrengthr {
50 label = "red:sigstrength";
51 gpios = <&gpio2 1 GPIO_ACTIVE_LOW>;
52 };
53
54 4g {
55 label = "green:4g";
56 gpios = <&gpio2 2 GPIO_ACTIVE_LOW>;
57 };
58
59 3g {
60 label = "green:3g";
61 gpios = <&gpio2 3 GPIO_ACTIVE_LOW>;
62 };
63
64 wifi {
65 label = "green:wifi";
66 gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
67 };
68 };
69
70 gpio_export {
71 compatible = "gpio-export";
72 #size-cells = <0>;
73
74 lte_modem_enable {
75 gpio-export,name = "lte_modem_enable";
76 gpio-export,output = <1>;
77 gpios = <&gpio0 0 GPIO_ACTIVE_HIGH>;
78 };
79 };
80 };
81
82 &gpio1 {
83 status = "okay";
84 };
85
86 &gpio2 {
87 status = "okay";
88 };
89
90 &gpio3 {
91 status = "okay";
92 };
93
94 &spi0 {
95 status = "okay";
96
97 flash@0 {
98 compatible = "jedec,spi-nor";
99 reg = <0>;
100 spi-max-frequency = <10000000>;
101
102 partitions {
103 compatible = "fixed-partitions";
104 #address-cells = <1>;
105 #size-cells = <1>;
106
107 partition@0 {
108 label = "jboot";
109 reg = <0x0 0x10000>;
110 read-only;
111 };
112
113 partition@10000 {
114 compatible = "amit,jimage";
115 label = "firmware";
116 reg = <0x10000 0xfe0000>;
117 };
118
119 config: partition@ff0000 {
120 label = "config";
121 reg = <0xff0000 0x10000>;
122 read-only;
123 };
124 };
125 };
126 };
127
128 &ehci {
129 status = "okay";
130 };
131
132 &ohci {
133 status = "okay";
134 };
135
136 &ethernet {
137 port@4 {
138 status = "okay";
139 };
140 };
141
142 &state_default {
143 default {
144 groups = "spi refclk", "i2c", "ephy", "wled";
145 function = "gpio";
146 };
147 };