ath79: qca956x: Update dts for current ag71xx driver
[oweals/openwrt.git] / target / linux / ath79 / dts / ar7161_netgear_wndr3800.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 "ar7100.dtsi"
8
9 / {
10         compatible = "netgear,wndr3800", "qca,ar7161";
11         model = "Netgear WNDR3800";
12
13         aliases {
14                 led-status = &power_green;
15         };
16
17         chosen {
18                 bootargs = "console=ttyS0,115200";
19         };
20
21         extosc: ref {
22                 compatible = "fixed-clock";
23                 #clock-cells = <0>;
24                 clock-output-names = "ref";
25                 clock-frequency = <40000000>;
26         };
27
28         reset-leds {
29                 compatible = "reset-leds";
30
31                 usb_led {
32                         label = "netgear:green:usb";
33                         resets = <&rst 12>;
34                         trigger-sources = <&usb_ochi_port>, <&usb_echi_port>;
35                         linux,default-trigger = "usbport";
36                 };
37         };
38
39         gpio-leds {
40                 compatible = "gpio-leds";
41
42                 wps {
43                         label = "netgear:orange:wps";
44                         gpios = <&gpio 0 GPIO_ACTIVE_LOW>;
45                         default-state = "off";
46                 };
47
48                 power_green: power_green {
49                         label = "netgear:green:power";
50                         gpios = <&gpio 2 GPIO_ACTIVE_LOW>;
51                         default-state = "off";
52                 };
53
54                 power_orange {
55                         label = "netgear:orange:power";
56                         gpios = <&gpio 1 GPIO_ACTIVE_LOW>;
57                         default-state = "off";
58                 };
59
60                 wps_green {
61                         label = "netgear:green:wps";
62                         gpios = <&gpio 4 GPIO_ACTIVE_LOW>;
63                         default-state = "off";
64                 };
65
66                 wan_green {
67                         label = "netgear:green:wan";
68                         gpios = <&gpio 6 GPIO_ACTIVE_LOW>;
69                         default-state = "off";
70                 };
71         };
72
73         gpio-keys-polled {
74                 compatible = "gpio-keys-polled";
75                 #address-cells = <1>;
76                 #size-cells = <0>;
77                 poll-interval = <100>;
78
79                 wps {
80                         label = "wps";
81                         linux,code = <KEY_WPS_BUTTON>;
82                         gpios = <&gpio 3 GPIO_ACTIVE_LOW>;
83                 };
84
85                 reset {
86                         label = "reset";
87                         linux,code = <KEY_RESTART>;
88                         gpios = <&gpio 8 GPIO_ACTIVE_LOW>;
89                 };
90
91                 rfkill {
92                         label = "rfkill";
93                         linux,code = <KEY_RFKILL>;
94                         gpios = <&gpio 11 GPIO_ACTIVE_LOW>;
95                 };
96         };
97
98         rtl8366s {
99                 compatible = "realtek,rtl8366s";
100                 gpio-sda = <&gpio 5 GPIO_ACTIVE_HIGH>;
101                 gpio-sck = <&gpio 7 GPIO_ACTIVE_HIGH>;
102
103                 mdio-bus {
104                         status = "okay";
105
106                         phy-mask = <0x10>;
107
108                         phy4: ethernet-phy@4 {
109                                 reg = <4>;
110                                 phy-mode = "rgmii";
111                         };
112                 };
113         };
114 };
115
116 &usb_phy {
117         status = "okay";
118 };
119
120 &usb1 {
121         status = "okay";
122
123         usb_ochi_port: port@1 {
124                 reg = <1>;
125                 #trigger-source-cells = <0>;
126         };
127 };
128
129 &usb2 {
130         status = "okay";
131
132         usb_echi_port: port@1 {
133                 reg = <1>;
134                 #trigger-source-cells = <0>;
135         };
136 };
137
138 &pcie0 {
139         status = "okay";
140 };
141
142 &uart {
143         status = "okay";
144 };
145
146 &spi {
147         status = "okay";
148         num-cs = <1>;
149
150         flash@0 {
151                 #address-cells = <1>;
152                 #size-cells = <1>;
153                 compatible = "mx25l12805d";
154                 reg = <0>;
155                 spi-max-frequency = <25000000>;
156
157                 partitions {
158                         compatible = "fixed-partitions";
159                         #address-cells = <1>;
160                         #size-cells = <1>;
161
162                         partition@0 {
163                                 label = "u-boot";
164                                 reg = <0x000000 0x050000>;
165                                 read-only;
166                         };
167
168                         partition@1 {
169                                 label = "u-boot-env";
170                                 reg = <0x050000 0x020000>;
171                                 read-only;
172                         };
173
174                         partition@2 {
175                                 label = "firmware";
176                                 reg = <0x070000 0xf80000>;
177                         };
178
179                         art: partition@3 {
180                                 label = "art";
181                                 reg = <0xff0000 0x010000>;
182                                 read-only;
183                         };
184                 };
185         };
186 };
187
188 &eth0 {
189         status = "okay";
190
191         pll-data = <0x11110000 0x00001099 0x00991099>;
192
193         mtd-mac-address = <&art 0x00>;
194
195         fixed-link {
196                 speed = <1000>;
197                 full-duplex;
198         };
199 };
200
201 &eth1 {
202         status = "okay";
203
204         pll-data = <0x11110000 0x00001099 0x00991099>;
205
206         mtd-mac-address = <&art 0x06>;
207
208         resets = <&rst 13>;
209         reset-names = "mac";
210
211         phy-handle = <&phy4>;
212 };