ramips: fix LAN LED trigger assignment for Xiaomi Router 3 Pro
[openwrt/openwrt.git] / target / linux / ramips / dts / rt5350_poray_m3.dts
1 #include "rt5350.dtsi"
2
3 #include <dt-bindings/gpio/gpio.h>
4 #include <dt-bindings/input/input.h>
5
6 / {
7 compatible = "poray,m3", "ralink,rt5350-soc";
8 model = "Poray M3";
9
10 aliases {
11 led-boot = &led_status;
12 led-failsafe = &led_status;
13 led-running = &led_status;
14 led-upgrade = &led_status;
15 };
16
17 leds {
18 compatible = "gpio-leds";
19
20 led_status: status {
21 label = "blue:status";
22 gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
23 };
24 };
25
26 keys {
27 compatible = "gpio-keys-polled";
28 poll-interval = <20>;
29
30 reset {
31 label = "reset";
32 gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
33 linux,code = <KEY_RESTART>;
34 };
35
36 mode {
37 label = "mode";
38 gpios = <&gpio0 17 GPIO_ACTIVE_LOW>;
39 linux,code = <BTN_0>;
40 linux,input-type = <EV_SW>;
41 };
42 };
43 };
44
45 &spi0 {
46 status = "okay";
47
48 flash@0 {
49 compatible = "jedec,spi-nor";
50 reg = <0>;
51 spi-max-frequency = <10000000>;
52
53 partitions {
54 compatible = "fixed-partitions";
55 #address-cells = <1>;
56 #size-cells = <1>;
57
58 partition@0 {
59 label = "u-boot";
60 reg = <0x0 0x30000>;
61 read-only;
62 };
63
64 partition@30000 {
65 label = "u-boot-env";
66 reg = <0x30000 0x10000>;
67 read-only;
68 };
69
70 factory: partition@40000 {
71 label = "factory";
72 reg = <0x40000 0x10000>;
73 read-only;
74 };
75
76 partition@50000 {
77 compatible = "denx,uimage";
78 label = "firmware";
79 reg = <0x50000 0x3b0000>;
80 };
81 };
82 };
83 };
84
85 &state_default {
86 gpio {
87 groups = "i2c", "jtag", "uartf";
88 function = "gpio";
89 };
90 };
91
92 &ethernet {
93 mtd-mac-address = <&factory 0x4>;
94 };
95
96 &esw {
97 mediatek,portmap = <0x2f>;
98 mediatek,led_polarity = <1>;
99 };
100
101 &wmac {
102 ralink,mtd-eeprom = <&factory 0x0>;
103 ralink,led-polarity = <1>;
104 };