ath79: fix dts whitespace
[openwrt/staging/hauke.git] / target / linux / ath79 / dts / ar9344_tplink_tl-wr841hp-v2.dts
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2
3 #include "ar9344.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9 model = "TP-Link TL-WR841HP v2";
10 compatible = "tplink,tl-wr841hp-v2", "qca,ar9344";
11
12 aliases {
13 led-boot = &led_system;
14 led-failsafe = &led_system;
15 led-running = &led_system;
16 led-upgrade = &led_system;
17 label-mac-device = &wmac;
18 };
19
20 keys {
21 compatible = "gpio-keys";
22
23 reset {
24 linux,code = <KEY_RESTART>;
25 gpios = <&gpio 4 GPIO_ACTIVE_HIGH>;
26 debounce-interval = <60>;
27 };
28 };
29
30 leds {
31 compatible = "gpio-leds";
32
33 wan {
34 label = "green:wan";
35 gpios = <&gpio 11 GPIO_ACTIVE_LOW>;
36 };
37
38 lan1 {
39 label = "green:lan1";
40 gpios = <&gpio 12 GPIO_ACTIVE_LOW>;
41 };
42
43 lan2 {
44 label = "green:lan2";
45 gpios = <&gpio 13 GPIO_ACTIVE_LOW>;
46 };
47
48 lan3 {
49 label = "green:lan3";
50 gpios = <&gpio 14 GPIO_ACTIVE_LOW>;
51 };
52
53 lan4 {
54 label = "green:lan4";
55 gpios = <&gpio 15 GPIO_ACTIVE_LOW>;
56 };
57
58 wps {
59 label = "green:wps";
60 gpios = <&gpio 16 GPIO_ACTIVE_LOW>;
61 };
62
63 wlan {
64 label = "green:wlan";
65 gpios = <&gpio 21 GPIO_ACTIVE_LOW>;
66 linux,default-trigger = "phy0tpt";
67 };
68
69 led_system: system {
70 label = "green:system";
71 gpios = <&gpio 22 GPIO_ACTIVE_LOW>;
72 default-state = "on";
73 };
74 };
75 };
76
77 &ref {
78 clock-frequency = <40000000>;
79 };
80
81 &spi {
82 status = "okay";
83
84 flash@0 {
85 compatible = "jedec,spi-nor";
86 reg = <0>;
87 spi-max-frequency = <25000000>;
88
89 partitions {
90 compatible = "fixed-partitions";
91 #address-cells = <1>;
92 #size-cells = <1>;
93
94 uboot: partition@0 {
95 label = "u-boot";
96 reg = <0x000000 0x020000>;
97 read-only;
98 };
99
100 partition@20000 {
101 compatible = "tplink,firmware";
102 label = "firmware";
103 reg = <0x020000 0x7d0000>;
104 };
105
106 art: partition@7f0000 {
107 label = "art";
108 reg = <0x7f0000 0x010000>;
109 read-only;
110 };
111 };
112 };
113 };
114
115 &gpio {
116 gpio_ext_lna0 {
117 gpio-hog;
118 gpios = <18 GPIO_ACTIVE_HIGH>;
119 output-high;
120 line-name = "tp-link:ext:lna0";
121 };
122
123 gpio_ext_lna1 {
124 gpio-hog;
125 gpios = <19 GPIO_ACTIVE_HIGH>;
126 output-high;
127 line-name = "tp-link:ext:lna1";
128 };
129 };
130
131 &wmac {
132 status = "okay";
133
134 mtd-cal-data = <&art 0x1000>;
135
136 nvmem-cells = <&macaddr_uboot_1fc00>;
137 nvmem-cell-names = "mac-address";
138 };
139
140 &eth0 {
141 status = "okay";
142
143 phy-handle = <&swphy0>;
144
145 nvmem-cells = <&macaddr_uboot_1fc00>;
146 nvmem-cell-names = "mac-address";
147 mac-address-increment = <1>;
148 };
149
150 &eth1 {
151 status = "okay";
152
153 nvmem-cells = <&macaddr_uboot_1fc00>;
154 nvmem-cell-names = "mac-address";
155
156 gmac-config {
157 device = <&gmac>;
158 switch-phy-swap = <1>;
159 };
160 };
161
162 &uboot {
163 compatible = "nvmem-cells";
164 #address-cells = <1>;
165 #size-cells = <1>;
166
167 macaddr_uboot_1fc00: macaddr@1fc00 {
168 reg = <0x1fc00 0x6>;
169 };
170 };