ath79: drop and consolidate redundant chosen/bootargs
[oweals/openwrt.git] / target / linux / ath79 / dts / qca9561_xiaomi_mi-router-4q.dts
1 // SPDX-License-Identifier: GPL-2.0+ OR MIT
2 /dts-v1/;
3
4 #include <dt-bindings/gpio/gpio.h>
5 #include <dt-bindings/input/input.h>
6
7 #include "qca956x.dtsi"
8
9 / {
10         compatible = "xiaomi,mi-router-4q", "qca,qca9560";
11         model = "Xiaomi Mi Router 4Q";
12
13         aliases {
14                 led-boot = &led_yellow;
15                 led-failsafe = &led_red;
16                 led-running = &led_blue;
17                 led-upgrade = &led_red;
18         };
19
20         keys {
21                 compatible = "gpio-keys";
22
23                 reset {
24                         label = "Reset button";
25                         linux,code = <KEY_RESTART>;
26                         gpios = <&gpio 21 GPIO_ACTIVE_LOW>;
27                 };
28
29                 wps {
30                         label = "WPS/MI button";
31                         linux,code = <KEY_WPS_BUTTON>;
32                         gpios = <&gpio 19 GPIO_ACTIVE_LOW>;
33                 };
34         };
35
36         leds {
37                 compatible = "gpio-leds";
38
39                 led_red: led_red {
40                         label = "mi-router-4q:red:led";
41                         gpios = <&gpio 1 GPIO_ACTIVE_LOW>;
42                 };
43
44                 led_yellow: led_yellow {
45                         label = "mi-router-4q:yellow:led";
46                         gpios = <&gpio 22 GPIO_ACTIVE_LOW>;
47                 };
48
49                 led_blue: led_blue {
50                         label = "mi-router-4q:blue:led";
51                         gpios = <&gpio 14 GPIO_ACTIVE_LOW>;
52                 };
53         };
54 };
55
56 &uart {
57         status = "okay";
58 };
59
60 &gpio {
61         status = "okay";
62 };
63
64 &spi {
65         status = "okay";
66         num-cs = <1>;
67
68         flash@0 {
69                 compatible = "jedec,spi-nor";
70                 reg = <0>;
71                 spi-max-frequency = <25000000>;
72
73                 partitions {
74                         compatible = "fixed-partitions";
75                         #address-cells = <1>;
76                         #size-cells = <1>;
77
78                         partition@0 {
79                                 label = "u-boot";
80                                 reg = <0x000000 0x30000>;
81                                 read-only;
82                         };
83
84                         partition@30000 {
85                                 label = "nvram";
86                                 reg = <0x030000 0x10000>;
87                                 read-only;
88                         };
89
90                         partition@40000 {
91                                 label = "boarddata";
92                                 reg = <0x40000 0x10000>;
93                                 read-only;
94                         };
95
96                         partition@50000 {
97                                 label = "crash";
98                                 reg = <0x50000 0x10000>;
99                                 read-only;
100                         };
101
102                         art: partition@60000 {
103                                 label = "art";
104                                 reg = <0x60000 0x10000>;
105                                 read-only;
106                         };
107
108                         partition@70000 {
109                                 label = "cfg_bak";
110                                 reg = <0x70000 0x20000>;
111                                 read-only;
112                         };
113
114                         partition@90000 {
115                                 label = "overlay";
116                                 reg = <0x90000 0x170000>;
117                                 read-only;
118                         };
119
120                         partition@200000 {
121                                 compatible = "denx,uimage";
122                                 label = "firmware";
123                                 reg = <0x200000 0xe00000>;
124                         };
125                 };
126         };
127 };
128
129 &eth0 {
130         status = "okay";
131
132         phy-handle = <&swphy4>;
133         mtd-mac-address = <&art 0x0>;
134 };
135
136 &eth1 {
137         status = "okay";
138
139         mtd-mac-address = <&art 0x6>;
140 };
141
142 &wmac {
143         status = "okay";
144
145         mtd-cal-data = <&art 0x1000>;
146         mtd-mac-address = <&art 0x0>;
147         mtd-mac-address-increment = <1>;
148 };