73f4ed0d1e1dd0c36ad6822c538cebb590bc67c5
[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 nvmem-layout {
125 compatible = "fixed-layout";
126 #address-cells = <1>;
127 #size-cells = <1>;
128
129 macaddr_art_0: macaddr@0 {
130 reg = <0x0 0x6>;
131 };
132
133 macaddr_art_6: macaddr@6 {
134 reg = <0x6 0x6>;
135 };
136
137 macaddr_art_c: macaddr@c {
138 reg = <0xc 0x6>;
139 };
140 };
141 };
142 };
143 };
144 };
145
146 &nand {
147 status = "okay";
148
149 partitions {
150 compatible = "fixed-partitions";
151 #address-cells = <1>;
152 #size-cells = <1>;
153
154 partition@0 {
155 label = "kernel";
156 reg = <0x0 0x500000>;
157 };
158
159 partition@500000 {
160 label = "ubi";
161 reg = <0x500000 0x5b00000>;
162 };
163
164 partition@6000000 {
165 label = "oem-backup";
166 reg = <0x6000000 0x2000000>;
167 };
168 };
169 };
170
171 &mdio0 {
172 status = "okay";
173
174 phy0: ethernet-phy@0 {
175 reg = <0>;
176
177 qca,ar8327-initvals = <
178 0x04 0x87600000 /* PORT0 PAD MODE CTRL */
179 0x0c 0x00080080 /* PORT6 PAD MODE CTRL */
180 0x7c 0x0000007e /* PORT0_STATUS */
181 0x94 0x0000007e /* PORT6 STATUS */
182 >;
183 };
184 };
185
186 &eth0 {
187 status = "okay";
188
189 nvmem-cells = <&macaddr_art_0>;
190 nvmem-cell-names = "mac-address";
191 pll-data = <0x56000000 0x00000101 0x00001616>;
192 phy-handle = <&phy0>;
193 };
194
195 &eth1 {
196 status = "okay";
197
198 nvmem-cells = <&macaddr_art_6>;
199 nvmem-cell-names = "mac-address";
200 pll-data = <0x03000101 0x00000101 0x00001616>;
201 fixed-link {
202 speed = <1000>;
203 full-duplex;
204 };
205 };
206
207 &wmac {
208 status = "okay";
209
210 mtd-cal-data = <&art 0x1000>;
211 nvmem-cells = <&macaddr_art_c>;
212 nvmem-cell-names = "mac-address";
213 };