ramips: add missing WAN LED for Xiaomi Mi Router 4A / 4C
[openwrt/staging/hauke.git] / target / linux / ramips / dts / mt7628an_xiaomi_mi-router-4.dtsi
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2
3 #include "mt7628an.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9 aliases {
10 led-boot = &led_power_yellow;
11 led-failsafe = &led_power_yellow;
12 led-running = &led_power_blue;
13 led-upgrade = &led_power_yellow;
14 label-mac-device = &ethernet;
15 };
16
17 chosen {
18 bootargs = "console=ttyS0,115200";
19 };
20
21 leds {
22 compatible = "gpio-leds";
23
24 led_power_blue: power_blue {
25 label = "blue:power";
26 gpios = <&gpio 11 GPIO_ACTIVE_LOW>;
27 };
28
29 led_power_yellow: power_yellow {
30 label = "yellow:power";
31 gpios = <&gpio 44 GPIO_ACTIVE_LOW>;
32 };
33
34 wan {
35 label = "blue:wan";
36 gpios = <&gpio 37 GPIO_ACTIVE_LOW>;
37 };
38 };
39
40 keys {
41 compatible = "gpio-keys";
42
43 reset {
44 label = "reset";
45 gpios = <&gpio 38 GPIO_ACTIVE_LOW>;
46 linux,code = <KEY_RESTART>;
47 };
48 };
49 };
50
51 &spi0 {
52 status = "okay";
53
54 flash0: flash@0 {
55 compatible = "jedec,spi-nor";
56 reg = <0>;
57 spi-max-frequency = <10000000>;
58
59 partitions: partitions {
60 compatible = "fixed-partitions";
61 #address-cells = <1>;
62 #size-cells = <1>;
63
64 partition@0 {
65 label = "bootloader";
66 reg = <0x0 0x20000>;
67 read-only;
68 };
69
70 partition@20000 {
71 label = "config";
72 reg = <0x20000 0x10000>;
73 read-only;
74 };
75
76 factory: partition@30000 {
77 label = "factory";
78 reg = <0x30000 0x10000>;
79 read-only;
80 };
81
82 partition@40000 {
83 label = "crash";
84 reg = <0x40000 0x10000>;
85 read-only;
86 };
87
88 partition@50000 {
89 label = "cfg_bak";
90 reg = <0x50000 0x10000>;
91 read-only;
92 };
93
94 /* additional partitions in DTS */
95 };
96 };
97 };
98
99 &state_default {
100 gpio {
101 groups = "gpio", "refclk", "wdt", "wled_an";
102 function = "gpio";
103 };
104 };
105
106 &wmac {
107 status = "okay";
108
109 mediatek,mtd-eeprom = <&factory 0x0>;
110 };