treewide: fix some cosmetic glitches in dts files
[openwrt/openwrt.git] / target / linux / ath79 / dts / ar7242_tplink_tl-wr2543-v1.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 "ar7242.dtsi"
8
9 / {
10 compatible = "tplink,tl-wr2543-v1", "qca,ar7242";
11 model = "TP-LINK TL-WR2543N/ND";
12
13 aliases {
14 led-boot = &system;
15 led-failsafe = &system;
16 led-running = &system;
17 led-upgrade = &system;
18 };
19
20 chosen {
21 bootargs = "console=ttyS0,115200n8";
22 };
23
24 extosc: ref {
25 compatible = "fixed-clock";
26 #clock-cells = <0>;
27 clock-frequency = <40000000>;
28 };
29
30 gpio-keys {
31 compatible = "gpio-keys-polled";
32 poll-interval = <20>;
33
34 reset {
35 label = "reset";
36 linux,code = <KEY_RESTART>;
37 gpios = <&gpio 11 GPIO_ACTIVE_LOW>;
38 debounce-interval = <60>;
39 };
40
41 wps {
42 label = "wps";
43 linux,code = <KEY_WPS_BUTTON>;
44 gpios = <&gpio 12 GPIO_ACTIVE_LOW>;
45 debounce-interval = <60>;
46 };
47 };
48
49 leds {
50 compatible = "gpio-leds";
51
52 system: wps {
53 label = "tplink:green:wps";
54 gpios = <&gpio 0 GPIO_ACTIVE_LOW>;
55 default-state = "off";
56 };
57
58 usb {
59 label = "tplink:green:usb";
60 gpios = <&gpio 8 GPIO_ACTIVE_LOW>;
61 default-state = "off";
62 trigger-sources = <&hub_port>;
63 linux,default-trigger = "usbport";
64 };
65 };
66
67 ath9k-leds {
68 compatible = "gpio-leds";
69
70 wlan2g {
71 label = "tplink:green:wlan2g";
72 gpios = <&ath9k 0 GPIO_ACTIVE_LOW>;
73 default-state = "off";
74 linux,default-trigger = "phy0tpt";
75 };
76
77 wlan5g {
78 label = "tplink:green:wlan5g";
79 gpios = <&ath9k 1 GPIO_ACTIVE_LOW>;
80 default-state = "off";
81 linux,default-trigger = "phy0tpt";
82 };
83 };
84
85 rtl8367 {
86 compatible = "realtek,rtl8367";
87 gpio-sda = <&gpio 1 GPIO_ACTIVE_HIGH>;
88 gpio-sck = <&gpio 6 GPIO_ACTIVE_HIGH>;
89 realtek,extif0 = <1 0 1 1 1 1 1 1 2>;
90
91 mdio-bus {
92 #address-cells = <1>;
93 #size-cells = <0>;
94 status = "okay";
95
96 phy0: ethernet-phy@0 {
97 reg = <0>;
98 };
99 };
100 };
101 };
102
103 &pll {
104 clocks = <&extosc>;
105 };
106
107 &spi {
108 status = "okay";
109 num-cs = <1>;
110
111 flash@0 {
112 compatible = "jedec,spi-nor";
113 reg = <0>;
114 spi-max-frequency = <25000000>;
115
116 partitions {
117 compatible = "fixed-partitions";
118 #address-cells = <1>;
119 #size-cells = <1>;
120
121 uboot: partition@0 {
122 label = "u-boot";
123 reg = <0x000000 0x020000>;
124 read-only;
125 };
126
127 partition@20000 {
128 label = "firmware";
129 reg = <0x020000 0x7d0000>;
130 };
131
132 partition@7f0000 {
133 label = "art";
134 reg = <0x7f0000 0x010000>;
135 read-only;
136 };
137 };
138 };
139 };
140
141 &uart {
142 status = "okay";
143 };
144
145 &usb {
146 #address-cells = <1>;
147 #size-cells = <0>;
148 status = "okay";
149
150 hub_port: port@1 {
151 reg = <1>;
152 #trigger-source-cells = <0>;
153 };
154 };
155
156 &usb_phy {
157 status = "okay";
158 };
159
160 &pcie {
161 status = "okay";
162
163 ath9k: wifi@0,0 {
164 reg = <0x0000 0 0 0 0>;
165 #gpio-cells = <2>;
166 gpio-controller;
167 qca,no-eeprom;
168 mtd-mac-address = <&uboot 0x1fc00>;
169 };
170 };
171
172 &eth0 {
173 status = "okay";
174
175 phy-mode = "rgmii";
176 mtd-mac-address = <&uboot 0x1fc00>;
177
178 phy-handle = <&phy0>;
179 fixed-link {
180 speed = <1000>;
181 full-duplex;
182 };
183 };