ath79: wdr4300: avoid DTC warnings
[oweals/openwrt.git] / target / linux / ath79 / dts / ar7241_ubnt_unifi.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 "ar7241.dtsi"
8
9 / {
10         compatible = "ubnt,unifi", "qca,ar7241";
11         model = "Ubiquiti UniFi AP";
12
13         memory@0 {
14                 device_type = "memory";
15                 reg = <0x0 0x4000000>;
16         };
17
18         extosc: ref {
19                 compatible = "fixed-clock";
20                 #clock-cells = <0>;
21                 clock-frequency = <40000000>;
22         };
23
24         keys {
25                 compatible = "gpio-keys-polled";
26                 #address-cells = <1>;
27                 #size-cells = <0>;
28
29                 poll-interval = <20>;
30                 button@0 {
31                         label = "reset";
32                         linux,code = <KEY_RESTART>;
33                         gpios = <&gpio 12 GPIO_ACTIVE_LOW>;
34                         debounce-interval = <60>;
35                 };
36         };
37
38         leds {
39                 compatible = "gpio-leds";
40                 led@0 {
41                         label = "ubnt:green:dome";
42                         gpios = <&gpio 0 GPIO_ACTIVE_HIGH>;
43                 };
44
45                 led@1 {
46                         label = "ubnt:orange:dome";
47                         gpios = <&gpio 1 GPIO_ACTIVE_HIGH>;
48                 };
49         };
50 };
51
52 &uart {
53         status = "okay";
54 };
55
56 &pll {
57         clocks = <&extosc>;
58 };
59
60 &spi {
61         status = "okay";
62         num-cs = <1>;
63
64         flash@0 {
65                 #address-cells = <1>;
66                 #size-cells = <1>;
67                 compatible = "mx25l6405d";
68                 reg = <0>;
69                 spi-max-frequency = <25000000>;
70
71                 partitions {
72                         compatible = "fixed-partitions";
73                         #address-cells = <1>;
74                         #size-cells = <1>;
75
76                         partition@0 {
77                                 label = "u-boot";
78                                 reg = <0x000000 0x040000>;
79                                 read-only;
80                         };
81
82                         partition@1 {
83                                 label = "u-boot-env";
84                                 reg = <0x040000 0x010000>;
85                         };
86
87                         partition@2 {
88                                 label = "firmware";
89                                 reg = <0x050000 0x750000>;
90                         };
91
92                         partition@3 {
93                                 label = "board_config";
94                                 reg = <0x7a0000 0x010000>;
95                                 read-only;
96                         };
97
98                         partition@4 {
99                                 label = "cfg";
100                                 reg = <0x7b0000 0x040000>;
101                                 read-only;
102                         };
103
104                         art: partition@5 {
105                                 label = "art";
106                                 reg = <0x7f0000 0x010000>;
107                                 read-only;
108                         };
109                 };
110         };
111 };
112
113 &pcie {
114         status = "okay";
115
116         ath9k@0000 {
117                 reg = <0x0000 0 0 0 0>;
118                 qca,no-eeprom;
119         };
120 };
121
122 &mdio0 {
123         status = "okay";
124
125         phy4: ethernet-phy@4 {
126                 reg = <4>;
127                 phy-mode = "mii";
128         };
129 };
130
131 &eth0 {
132         status = "okay";
133
134         mtd-mac-address = <&art 0x0>;
135         phy-handle = <&phy4>;
136 };
137
138 &eth1 {
139         status = "okay";
140
141         compatible = "syscon";
142 };