ramips: fix LAN LED trigger assignment for Xiaomi Router 3 Pro
[openwrt/openwrt.git] / target / linux / ramips / dts / mt7628an_alfa-network_awusfree1.dts
1 // SPDX-License-Identifier: BSD-3-Clause
2 /*
3 * Copyright (C) 2018 Piotr Dymacz <pepe2k@gmail.com>
4 * All rights reserved.
5 */
6
7 #include "mt7628an.dtsi"
8
9 #include <dt-bindings/gpio/gpio.h>
10 #include <dt-bindings/input/input.h>
11
12 / {
13 compatible = "alfa-network,awusfree1", "mediatek,mt7628an-soc";
14 model = "ALFA Network AWUSFREE1";
15
16 aliases {
17 led-boot = &led_system;
18 led-failsafe = &led_system;
19 led-running = &led_system;
20 led-upgrade = &led_system;
21 };
22
23 chosen {
24 bootargs = "console=ttyS0,115200";
25 };
26
27 keys {
28 compatible = "gpio-keys";
29
30 reset {
31 label = "reset";
32 gpios = <&gpio 38 GPIO_ACTIVE_LOW>;
33 linux,code = <KEY_RESTART>;
34 };
35 };
36
37 leds {
38 compatible = "gpio-leds";
39
40 led_system: system {
41 label = "orange:system";
42 gpios = <&gpio 43 GPIO_ACTIVE_LOW>;
43 };
44
45 wlan {
46 label = "blue:wlan";
47 gpios = <&gpio 44 GPIO_ACTIVE_LOW>;
48 };
49 };
50 };
51
52 &ehci {
53 status = "disabled";
54 };
55
56 &esw {
57 mediatek,portdisable = <0x1e>;
58 };
59
60 &ethernet {
61 mtd-mac-address = <&factory 0x2e>;
62 };
63
64 &ohci {
65 status = "disabled";
66 };
67
68 &state_default {
69 gpio {
70 groups = "p0led_an", "wdt", "wled_an";
71 function = "gpio";
72 };
73
74 ext_lna {
75 groups = "uart1";
76 function = "sw_r";
77 };
78
79 ext_pa {
80 groups = "i2s";
81 function = "antenna";
82 };
83 };
84
85 &spi0 {
86 status = "okay";
87
88 flash@0 {
89 compatible = "jedec,spi-nor";
90 reg = <0>;
91 spi-max-frequency = <10000000>;
92
93 partitions {
94 compatible = "fixed-partitions";
95 #address-cells = <1>;
96 #size-cells = <1>;
97
98 partition@0 {
99 label = "u-boot";
100 reg = <0x0 0x30000>;
101 read-only;
102 };
103
104 partition@30000 {
105 label = "u-boot-env";
106 reg = <0x30000 0x1000>;
107 };
108
109 partition@31000 {
110 label = "config";
111 reg = <0x31000 0xf000>;
112 read-only;
113 };
114
115 factory: partition@40000 {
116 label = "factory";
117 reg = <0x40000 0x10000>;
118 read-only;
119 };
120
121 partition@50000 {
122 compatible = "denx,uimage";
123 label = "firmware";
124 reg = <0x50000 0x7b0000>;
125 };
126 };
127 };
128 };
129
130 &wmac {
131 status = "okay";
132 };