ath79: add support for COMFAST CF-E380AC v2
[openwrt/openwrt.git] / target / linux / ath79 / dts / qca9558_domywifi_dw33d.dts
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2
3 #include "qca955x.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9 compatible = "domywifi,dw33d", "qca,qca9558";
10 model = "DomyWifi DW33D";
11
12 aliases {
13 led-boot = &led_system;
14 led-failsafe = &led_system;
15 led-running = &led_system;
16 led-upgrade = &led_system;
17 };
18
19 leds {
20 compatible = "gpio-leds";
21
22 led_system: system {
23 label = "blue:system";
24 gpios = <&gpio 14 GPIO_ACTIVE_LOW>;
25 };
26
27 mmc {
28 label = "blue:mmc";
29 gpios = <&gpio 4 GPIO_ACTIVE_LOW>;
30 trigger-sources = <&hub_port0>;
31 linux,default-trigger = "usbport";
32 };
33
34 usb {
35 label = "blue:usb";
36 gpios = <&gpio 15 GPIO_ACTIVE_LOW>;
37 trigger-sources = <&hub_port1>;
38 linux,default-trigger = "usbport";
39 };
40
41 wlan2g {
42 label = "blue:wlan2g";
43 gpios = <&gpio 13 GPIO_ACTIVE_LOW>;
44 linux,default-trigger = "phy1tpt";
45 };
46
47 internet {
48 label = "blue:internet";
49 gpios = <&gpio 22 GPIO_ACTIVE_LOW>;
50 };
51 };
52
53 keys {
54 compatible = "gpio-keys";
55
56 reset {
57 label = "Reset button";
58 linux,code = <KEY_RESTART>;
59 gpios = <&gpio 17 GPIO_ACTIVE_LOW>;
60 debounce-interval = <60>;
61 };
62 };
63 };
64
65 &pcie0 {
66 status = "okay";
67
68 wifi@0,0 {
69 compatible = "qcom,ath10k";
70 reg = <0 0 0 0 0>;
71 };
72 };
73
74 &usb_phy0 {
75 status = "okay";
76 };
77
78 &usb0 {
79 status = "okay";
80 };
81
82 &usb_phy1 {
83 status = "okay";
84 };
85
86 &usb1 {
87 status = "okay";
88 };
89
90 &spi {
91 status = "okay";
92
93 flash@0 {
94 compatible = "jedec,spi-nor";
95 reg = <0>;
96 spi-max-frequency = <25000000>;
97
98 partitions {
99 compatible = "fixed-partitions";
100 #address-cells = <1>;
101 #size-cells = <1>;
102
103 partition@0 {
104 label = "u-boot";
105 reg = <0x0 0x40000>;
106 read-only;
107 };
108
109 partition@40000 {
110 label = "u-boot-env";
111 reg = <0x40000 0x10000>;
112 };
113
114 partition@50000 {
115 label = "oem-firmware";
116 reg = <0x50000 0xfa0000>;
117 };
118
119 art: partition@ff0000 {
120 label = "art";
121 reg = <0xff0000 0x10000>;
122 read-only;
123 };
124 };
125 };
126 };
127
128 &nand {
129 status = "okay";
130
131 partitions {
132 compatible = "fixed-partitions";
133 #address-cells = <1>;
134 #size-cells = <1>;
135
136 partition@0 {
137 label = "kernel";
138 reg = <0x0 0x500000>;
139 };
140
141 partition@500000 {
142 label = "ubi";
143 reg = <0x500000 0x5b00000>;
144 };
145
146 partition@6000000 {
147 label = "oem-backup";
148 reg = <0x6000000 0x2000000>;
149 };
150 };
151 };
152
153 &mdio0 {
154 status = "okay";
155
156 phy0: ethernet-phy@0 {
157 reg = <0>;
158
159 qca,ar8327-initvals = <
160 0x04 0x87600000 /* PORT0 PAD MODE CTRL */
161 0x0c 0x00080080 /* PORT6 PAD MODE CTRL */
162 0x7c 0x0000007e /* PORT0_STATUS */
163 0x94 0x0000007e /* PORT6 STATUS */
164 >;
165 };
166 };
167
168 &eth0 {
169 status = "okay";
170
171 nvmem-cells = <&macaddr_art_0>;
172 nvmem-cell-names = "mac-address";
173 pll-data = <0x56000000 0x00000101 0x00001616>;
174 phy-handle = <&phy0>;
175 };
176
177 &eth1 {
178 status = "okay";
179
180 nvmem-cells = <&macaddr_art_6>;
181 nvmem-cell-names = "mac-address";
182 pll-data = <0x03000101 0x00000101 0x00001616>;
183 fixed-link {
184 speed = <1000>;
185 full-duplex;
186 };
187 };
188
189 &wmac {
190 status = "okay";
191
192 mtd-cal-data = <&art 0x1000>;
193 nvmem-cells = <&macaddr_art_c>;
194 nvmem-cell-names = "mac-address";
195 };
196
197 &art {
198 compatible = "nvmem-cells";
199 #address-cells = <1>;
200 #size-cells = <1>;
201
202 macaddr_art_0: macaddr@0 {
203 reg = <0x0 0x6>;
204 };
205
206 macaddr_art_6: macaddr@6 {
207 reg = <0x6 0x6>;
208 };
209
210 macaddr_art_c: macaddr@c {
211 reg = <0xc 0x6>;
212 };
213 };