ramips: convert to new LED color/function format where possible
[openwrt/openwrt.git] / target / linux / ramips / dts / mt7628an_xiaomi_mi-router-4c.dts
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2
3 #include <dt-bindings/leds/common.h>
4
5 #include "mt7628an_xiaomi_mi-router-4.dtsi"
6
7 / {
8 compatible = "xiaomi,mi-router-4c", "mediatek,mt7628an-soc";
9 model = "Xiaomi Mi Router 4C";
10
11 aliases {
12 led-boot = &led_power_yellow;
13 led-failsafe = &led_power_yellow;
14 led-running = &led_power_blue;
15 led-upgrade = &led_power_yellow;
16 label-mac-device = &ethernet;
17 };
18
19 leds {
20 compatible = "gpio-leds";
21
22 led_power_blue: power_blue {
23 function = LED_FUNCTION_POWER;
24 color = <LED_COLOR_ID_BLUE>;
25 gpios = <&gpio 11 GPIO_ACTIVE_LOW>;
26 };
27
28 led_power_yellow: power_yellow {
29 function = LED_FUNCTION_POWER;
30 color = <LED_COLOR_ID_YELLOW>;
31 gpios = <&gpio 44 GPIO_ACTIVE_LOW>;
32 };
33
34 wan {
35 function = LED_FUNCTION_WAN;
36 color = <LED_COLOR_ID_BLUE>;
37 gpios = <&gpio 37 GPIO_ACTIVE_LOW>;
38 };
39
40 };
41
42 };
43
44 &flash0 {
45 spi-max-frequency = <40000000>;
46 };
47
48 &partitions {
49 partition@60000 {
50 label = "overlay";
51 reg = <0x60000 0x100000>;
52 read-only;
53 };
54
55 partition@160000 {
56 label = "firmware";
57 reg = <0x160000 0xea0000>;
58 compatible = "denx,uimage";
59 };
60 };
61
62 &ehci {
63 status = "disabled";
64 };
65
66 &ohci {
67 status = "disabled";
68 };
69
70 &ethernet {
71 nvmem-cells = <&macaddr_factory_28>;
72 nvmem-cell-names = "mac-address";
73 };
74
75 &esw {
76 mediatek,portmap = <0x3d>;
77 mediatek,portdisable = <0x29>;
78 };