ath79: qca955x: remove redundant phy-mode
[openwrt/openwrt.git] / target / linux / ath79 / dts / qca9563_netgear_wndr.dtsi
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2
3 #include "qca956x.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9 aliases {
10 led-boot = &led_power_amber;
11 led-failsafe = &led_power_amber;
12 led-running = &led_power_green;
13 led-upgrade = &led_power_amber;
14 label-mac-device = &eth0;
15 };
16
17 keys {
18 compatible = "gpio-keys";
19
20 wps {
21 label = "wps";
22 linux,code = <KEY_WPS_BUTTON>;
23 gpios = <&gpio 1 GPIO_ACTIVE_LOW>;
24 };
25
26 reset {
27 label = "reset";
28 linux,code = <KEY_RESTART>;
29 gpios = <&gpio 2 GPIO_ACTIVE_LOW>;
30 };
31 };
32
33 ath9k-keys {
34 compatible = "gpio-keys-polled";
35 poll-interval = <20>;
36
37 rfkill {
38 label = "rfkill";
39 linux,code = <KEY_RFKILL>;
40 gpios = <&ath9k 9 GPIO_ACTIVE_LOW>;
41 debounce-interval = <60>;
42 };
43 };
44
45 leds: leds {
46 compatible = "gpio-leds";
47
48 pinctrl-names = "default";
49 pinctrl-0 = <&jtag_disable_pins>;
50
51 led_power_green: power_green {
52 label = "green:power";
53 gpios = <&gpio 5 GPIO_ACTIVE_LOW>;
54 };
55
56 led_power_amber: power_amber {
57 label = "amber:power";
58 gpios = <&gpio 6 GPIO_ACTIVE_LOW>;
59 default-state = "keep";
60 };
61
62 wan_green {
63 label = "green:wan";
64 gpios = <&gpio 17 GPIO_ACTIVE_LOW>;
65 };
66
67 wan_amber {
68 label = "amber:wan";
69 gpios = <&gpio 16 GPIO_ACTIVE_LOW>;
70 };
71
72 wlan2g_green {
73 label = "green:wlan2g";
74 gpios = <&gpio 19 GPIO_ACTIVE_LOW>;
75 linux,default-trigger = "phy0tpt";
76 };
77
78 wps_green {
79 label = "green:wps";
80 gpios = <&gpio 15 GPIO_ACTIVE_LOW>;
81 };
82 };
83
84 ath9k-leds {
85 compatible = "gpio-leds";
86
87 wlan5g_blue {
88 label = "blue:wlan5g";
89 gpios = <&ath9k 7 GPIO_ACTIVE_LOW>;
90 linux,default-trigger = "phy1tpt";
91 };
92 };
93 };
94
95 &spi {
96 status = "okay";
97
98 flash@0 {
99 compatible = "jedec,spi-nor";
100 reg = <0>;
101 spi-max-frequency = <25000000>;
102
103 partitions {
104 compatible = "fixed-partitions";
105 #address-cells = <1>;
106 #size-cells = <1>;
107
108 partition@0 {
109 label = "u-boot";
110 reg = <0x0 0x40000>;
111 read-only;
112 };
113
114 partition@40000 {
115 label = "u-boot-env";
116 reg = <0x40000 0x10000>;
117 };
118
119 partition@50000 {
120 label = "caldata_backup";
121 reg = <0x50000 0x10000>;
122 read-only;
123 };
124
125 partition@60000 {
126 label = "config";
127 reg = <0x60000 0x10000>;
128 };
129
130 partition@70000 {
131 label = "traffic_meter";
132 reg = <0x70000 0x10000>;
133 };
134
135 partition@80000 {
136 label = "pot";
137 reg = <0x80000 0x10000>;
138 };
139
140 partition@90000 {
141 label = "reserved";
142 reg = <0x90000 0x160000>;
143 };
144
145 caldata: partition@1f0000 {
146 label = "caldata";
147 reg = <0x1f0000 0x10000>;
148 read-only;
149 };
150 };
151 };
152
153 flash@1 {
154 compatible = "spi-nand";
155 reg = <1>;
156 spi-max-frequency = <25000000>;
157
158 partitions {
159 compatible = "fixed-partitions";
160 #address-cells = <1>;
161 #size-cells = <1>;
162
163 partition@0 {
164 label = "kernel";
165 reg = <0x0 0x400000>;
166 };
167
168 partition@400000 {
169 label = "ubi";
170 reg = <0x400000 0x7c00000>;
171 };
172 };
173 };
174 };
175
176 &mdio0 {
177 status = "okay";
178
179 phy-mask = <0>;
180
181 phy0: ethernet-phy@0 {
182 reg = <0>;
183 phy-mode = "sgmii";
184 qca,mib-poll-interval = <500>;
185
186 qca,ar8327-initvals = <
187 0x04 0x00000080 /* PORT0 PAD MODE CTRL */
188 0x10 0x81000080 /* POWER_ON_STRAP */
189 0x50 0xcc35cc35 /* LED_CTRL0 */
190 0x54 0xcb37cb37 /* LED_CTRL1 */
191 0x58 0x00000000 /* LED_CTRL2 */
192 0x5c 0x00f3cf00 /* LED_CTRL3 */
193 0x7c 0x0000007e /* PORT0_STATUS */
194 0x94 0x00000200 /* PORT6_STATUS */
195 >;
196 };
197 };
198
199 &eth0 {
200 status = "okay";
201
202 pll-data = <0x03000101 0x00000101 0x00001919>;
203
204 mtd-mac-address = <&caldata 0x0>;
205
206 phy-mode = "sgmii";
207 phy-handle = <&phy0>;
208 };
209
210 &wmac {
211 status = "okay";
212
213 mtd-mac-address = <&caldata 0x0>;
214 qca,no-eeprom;
215 };
216
217 &pcie {
218 status = "okay";
219
220 ath9k: wifi@0,0 {
221 /* chip is AR9580, override bogus PCI ID 168c:abcd */
222 compatible = "pci168c,0033";
223 reg = <0x0000 0 0 0 0>;
224 mtd-mac-address = <&caldata 0xc>;
225 qca,no-eeprom;
226 qca,gpio-mask=<0xf6ff>; /* unmask pin 9 for RFKILL button */
227 #gpio-cells = <2>;
228 gpio-controller;
229 };
230 };
231
232 &usb_phy0 {
233 status = "okay";
234 };
235
236 &usb0 {
237 #address-cells = <1>;
238 #size-cells = <0>;
239 status = "okay";
240
241 hub_port0: port@1 {
242 reg = <1>;
243 #trigger-source-cells = <0>;
244 };
245 };
246
247 &uart {
248 status = "okay";
249 };