ramips: fix LAN LED trigger assignment for Xiaomi Router 3 Pro
[openwrt/openwrt.git] / target / linux / ramips / dts / mt7620n_asus_rt-n12p.dts
1 #include "mt7620n.dtsi"
2
3 #include <dt-bindings/gpio/gpio.h>
4 #include <dt-bindings/input/input.h>
5
6 / {
7 compatible = "asus,rt-n12p", "ralink,mt7620n-soc";
8 model = "Asus RT-N12+";
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=ttyS0,115200";
19 };
20
21 leds {
22 compatible = "gpio-leds";
23
24 wan {
25 label = "green:wan";
26 gpios = <&gpio2 4 GPIO_ACTIVE_LOW>;
27 };
28
29 lan {
30 label = "green:lan";
31 gpios = <&gpio1 15 GPIO_ACTIVE_LOW>;
32 };
33
34 led_power: power {
35 label = "green:power";
36 gpios = <&gpio2 3 GPIO_ACTIVE_LOW>;
37 };
38
39 air {
40 label = "green:air";
41 gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
42 };
43 };
44
45 keys {
46 compatible = "gpio-keys";
47
48 reset {
49 label = "reset";
50 gpios = <&gpio0 17 GPIO_ACTIVE_LOW>;
51 linux,code = <KEY_RESTART>;
52 };
53 };
54 };
55
56 &gpio1 {
57 status = "okay";
58 };
59
60 &gpio2 {
61 status = "okay";
62 };
63
64 &gpio3 {
65 status = "okay";
66 };
67
68 &spi0 {
69 status = "okay";
70
71 flash@0 {
72 compatible = "jedec,spi-nor";
73 reg = <0>;
74 spi-max-frequency = <10000000>;
75
76 partitions {
77 compatible = "fixed-partitions";
78 #address-cells = <1>;
79 #size-cells = <1>;
80
81 partition@0 {
82 label = "u-boot";
83 reg = <0x0 0x30000>;
84 read-only;
85 };
86
87 partition@30000 {
88 label = "u-boot-env";
89 reg = <0x30000 0x10000>;
90 read-only;
91 };
92
93 factory: partition@40000 {
94 label = "factory";
95 reg = <0x40000 0x10000>;
96 read-only;
97 };
98
99 partition@50000 {
100 compatible = "denx,uimage";
101 label = "firmware";
102 reg = <0x50000 0xfb0000>;
103 };
104 };
105 };
106 };
107
108 &ethernet {
109 mtd-mac-address = <&factory 0x4>;
110
111 mediatek,portmap = "llllw";
112 };
113
114 &wmac {
115 ralink,mtd-eeprom = <&factory 0x0>;
116 };
117
118 &state_default {
119 default {
120 groups = "ephy", "wled", "i2c", "wdt", "pa", "spi refclk";
121 function = "gpio";
122 };
123 };