ath79: fix whitespace issues in DTS files
[openwrt/openwrt.git] / target / linux / ath79 / dts / ar7161_dlink_dir-825-b1.dts
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2 /dts-v1/;
3
4 #include <dt-bindings/gpio/gpio.h>
5 #include <dt-bindings/input/input.h>
6
7 #include "ar7100.dtsi"
8
9 / {
10 compatible = "dlink,dir-825-b1", "qca,ar7161";
11 model = "D-Link DIR825B1";
12
13 aliases {
14 led-boot = &orange_power;
15 led-failsafe = &orange_power;
16 led-running = &blue_power;
17 led-upgrade = &orange_power;
18 };
19
20 chosen {
21 bootargs = "console=ttyS0,115200";
22 };
23
24 extosc: ref {
25 compatible = "fixed-clock";
26 #clock-cells = <0>;
27 clock-output-names = "ref";
28 clock-frequency = <40000000>;
29 };
30
31 leds {
32 compatible = "gpio-leds";
33 blue_usb {
34 label = "d-link:blue:usb";
35 gpios = <&gpio 0 GPIO_ACTIVE_LOW>;
36 trigger-sources = <&usb_ochi_port>, <&usb_echi_port>;
37 linux,default-trigger = "usbport";
38 };
39
40 orange_power: orange_power {
41 label = "d-link:orange:power";
42 gpios = <&gpio 1 GPIO_ACTIVE_LOW>;
43 default-state = "on";
44 };
45
46 blue_power: blue_power {
47 label = "d-link:blue:power";
48 gpios = <&gpio 2 GPIO_ACTIVE_LOW>;
49 };
50
51 blue_wps {
52 label = "d-link:blue:wps";
53 gpios = <&gpio 4 GPIO_ACTIVE_LOW>;
54 };
55
56 orange_planet {
57 label = "d-link:orange:planet";
58 gpios = <&gpio 6 GPIO_ACTIVE_LOW>;
59 };
60
61 blue_planet {
62 label = "d-link:blue:planet";
63 gpios = <&gpio 11 GPIO_ACTIVE_LOW>;
64 };
65 };
66
67 ath9k-leds {
68 compatible = "gpio-leds";
69
70 wlan2g {
71 label = "d-link:blue:wlan2g";
72 gpios = <&ath9k0 5 GPIO_ACTIVE_LOW>;
73 linux,default-trigger = "phy0tpt";
74 };
75
76 wlan5g {
77 label = "d-link:blue:wlan5g";
78 gpios = <&ath9k1 5 GPIO_ACTIVE_LOW>;
79 linux,default-trigger = "phy1tpt";
80 };
81 };
82
83 keys {
84 compatible = "gpio-keys";
85
86 reset {
87 label = "reset";
88 linux,code = <KEY_RESTART>;
89 gpios = <&gpio 3 GPIO_ACTIVE_LOW>;
90 };
91
92 wps {
93 label = "wps";
94 linux,code = <KEY_WPS_BUTTON>;
95 gpios = <&gpio 8 GPIO_ACTIVE_LOW>;
96 };
97 };
98
99 rtl8366s {
100 compatible = "realtek,rtl8366s";
101 gpio-sda = <&gpio 5 GPIO_ACTIVE_HIGH>;
102 gpio-sck = <&gpio 7 GPIO_ACTIVE_HIGH>;
103 realtek,initvals = <0x06 0x0108>;
104
105 mdio-bus {
106 #address-cells = <1>;
107 #size-cells = <0>;
108 status = "okay";
109
110 phy-mask = <0x10>;
111
112 phy4: ethernet-phy@4 {
113 reg = <4>;
114 phy-mode = "rgmii";
115 };
116 };
117 };
118 };
119
120 &usb1 {
121 #address-cells = <1>;
122 #size-cells = <0>;
123 status = "okay";
124
125 usb_ochi_port: port@1 {
126 reg = <1>;
127 #trigger-source-cells = <0>;
128 };
129 };
130
131 &usb2 {
132 #address-cells = <1>;
133 #size-cells = <0>;
134 status = "okay";
135
136 usb_echi_port: port@1 {
137 reg = <1>;
138 #trigger-source-cells = <0>;
139 };
140 };
141
142 &usb_phy {
143 status = "okay";
144 };
145
146 &pcie0 {
147 status = "okay";
148
149 ath9k0: wifi@0,11 {
150 compatible = "pci168c,0029";
151 reg = <0x8800 0 0 0 0>;
152 qca,no-eeprom;
153 #gpio-cells = <2>;
154 gpio-controller;
155 };
156
157 ath9k1: wifi@0,12 {
158 compatible = "pci168c,0029";
159 reg = <0x9000 0 0 0 0>;
160 qca,no-eeprom;
161 #gpio-cells = <2>;
162 gpio-controller;
163 };
164 };
165
166 &uart {
167 status = "okay";
168 };
169
170 &pll {
171 clocks = <&extosc>;
172 };
173
174 &spi {
175 status = "okay";
176 num-cs = <1>;
177
178 flash@0 {
179 compatible = "jedec,spi-nor";
180 reg = <0>;
181 spi-max-frequency = <25000000>;
182
183 partitions {
184 compatible = "fixed-partitions";
185 #address-cells = <1>;
186 #size-cells = <1>;
187
188 partition@0 {
189 label = "u-boot";
190 reg = <0x000000 0x040000>;
191 read-only;
192 };
193
194 partition@40000 {
195 label = "config";
196 reg = <0x040000 0x010000>;
197 read-only;
198 };
199
200 partition@50000 {
201 compatible = "denx,uimage";
202 label = "firmware";
203 reg = <0x050000 0x610000>;
204 };
205
206 caldata: partition@60000 {
207 label = "caldata";
208 reg = <0x660000 0x010000>;
209 read-only;
210 };
211
212 partition@670000 {
213 label = "unknown";
214 reg = <0x670000 0x190000>;
215 read-only;
216 };
217 };
218 };
219 };
220
221 &eth0 {
222 status = "okay";
223 pll-data = <0x11110000 0x00001099 0x00991099>;
224
225 fixed-link {
226 speed = <1000>;
227 full-duplex;
228 };
229 };
230
231 &eth1 {
232 status = "okay";
233 pll-data = <0x11110000 0x00001099 0x00991099>;
234
235 phy-handle = <&phy4>;
236 };