ramips: improve Xiaomi mi-mini indications
[openwrt/openwrt.git] / target / linux / ramips / dts / mt7621_thunder_timecloud.dts
1 #include "mt7621.dtsi"
2
3 #include <dt-bindings/gpio/gpio.h>
4 #include <dt-bindings/input/input.h>
5
6 / {
7 compatible = "thunder,timecloud", "mediatek,mt7621-soc";
8 model = "Thunder Timecloud";
9
10 aliases {
11 led-boot = &led_statuso;
12 led-failsafe = &led_statuso;
13 led-running = &led_statuso;
14 led-upgrade = &led_statuso;
15 };
16
17 chosen {
18 bootargs = "console=ttyS0,115200";
19 };
20
21 leds {
22 compatible = "gpio-leds";
23
24 statw {
25 label = "white:status";
26 gpios = <&gpio 7 GPIO_ACTIVE_HIGH>;
27 };
28
29 led_statuso: stato {
30 label = "orange:status";
31 gpios = <&gpio 8 GPIO_ACTIVE_HIGH>;
32 };
33 };
34
35 keys {
36 compatible = "gpio-keys";
37
38 reset {
39 label = "reset";
40 gpios = <&gpio 13 GPIO_ACTIVE_LOW>;
41 linux,code = <KEY_RESTART>;
42 };
43
44 BTN_0 {
45 label = "BTN_0";
46 gpios = <&gpio 4 GPIO_ACTIVE_LOW>;
47 linux,code = <BTN_0>;
48 };
49 };
50 };
51
52 &sdhci {
53 status = "okay";
54 };
55
56 &spi0 {
57 status = "okay";
58
59 flash@0 {
60 compatible = "jedec,spi-nor";
61 reg = <0>;
62 spi-max-frequency = <10000000>;
63
64 partitions {
65 compatible = "fixed-partitions";
66 #address-cells = <1>;
67 #size-cells = <1>;
68
69 partition@0 {
70 label = "u-boot";
71 reg = <0x0 0x30000>;
72 read-only;
73 };
74
75 partition@30000 {
76 label = "u-boot-env";
77 reg = <0x30000 0x10000>;
78 read-only;
79 };
80
81 factory: partition@40000 {
82 label = "factory";
83 reg = <0x40000 0x10000>;
84 read-only;
85 };
86
87 partition@50000 {
88 compatible = "denx,uimage";
89 label = "firmware";
90 reg = <0x50000 0xfb0000>;
91 };
92 };
93 };
94 };
95
96 &gmac0 {
97 nvmem-cells = <&macaddr_factory_e000>;
98 nvmem-cell-names = "mac-address";
99 };
100
101 &switch0 {
102 ports {
103 port@4 {
104 status = "okay";
105 label = "lan";
106 };
107 };
108 };
109
110 &state_default {
111 gpio {
112 groups = "i2c", "uart2", "jtag";
113 function = "gpio";
114 };
115 };
116
117 &factory {
118 compatible = "nvmem-cells";
119 #address-cells = <1>;
120 #size-cells = <1>;
121
122 macaddr_factory_e000: macaddr@e000 {
123 reg = <0xe000 0x6>;
124 };
125 };