ath79: fix dts of Teltonika RUT9xx devices
[openwrt/staging/wigyori.git] / target / linux / ath79 / dts / qca9563_nec_wg1200cr.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 "qca956x.dtsi"
8
9 / {
10 model = "NEC Aterm WG1200CR";
11 compatible = "nec,wg1200cr", "qca,qca9563";
12
13 chosen {
14 bootargs = "console=ttyS0,115200n8";
15 };
16
17 aliases {
18 led-boot = &led_power_green;
19 led-failsafe = &led_power_red;
20 led-running = &led_power_green;
21 led-upgrade = &led_power_green;
22 };
23
24 leds {
25 compatible = "gpio-leds";
26 /* other LEDs are connected to ath10k (QCA9888) gpiochip */
27
28 led_power_green: power_green {
29 label = "wg1200cr:green:power";
30 gpios = <&gpio 5 GPIO_ACTIVE_LOW>;
31 default-state = "on";
32 };
33
34 led_power_red: power_red {
35 label = "wg1200cr:red:power";
36 gpios = <&gpio 6 GPIO_ACTIVE_LOW>;
37 };
38 };
39
40 keys {
41 compatible = "gpio-keys";
42
43 reset {
44 label = "reset";
45 gpios = <&gpio 1 GPIO_ACTIVE_LOW>;
46 linux,code = <KEY_RESTART>;
47 debounce-interval = <60>;
48 };
49
50 wps {
51 label = "wps";
52 gpios = <&gpio 2 GPIO_ACTIVE_LOW>;
53 linux,code = <KEY_WPS_BUTTON>;
54 debounce-interval = <60>;
55 };
56
57 bridge {
58 label = "br";
59 gpios = <&gpio 7 GPIO_ACTIVE_LOW>;
60 linux,code = <BTN_0>;
61 linux,input-type = <EV_SW>;
62 debounce-interval = <60>;
63 };
64
65 converter {
66 label = "cnv";
67 gpios = <&gpio 8 GPIO_ACTIVE_LOW>;
68 linux,code = <BTN_0>;
69 linux,input-type = <EV_SW>;
70 debounce-interval = <60>;
71 };
72 };
73 };
74
75 &spi {
76 status = "okay";
77
78 num-cs = <1>;
79
80 flash@0 {
81 compatible = "jedec,spi-nor";
82 reg = <0>;
83 spi-max-frequency = <25000000>;
84
85 partitions {
86 compatible = "fixed-partitions";
87 #address-cells = <1>;
88 #size-cells = <1>;
89
90 partition@0 {
91 label = "u-boot";
92 reg = <0x000000 0x040000>;
93 read-only;
94 };
95
96 partition@40000 {
97 label = "devdata";
98 reg = <0x040000 0x010000>;
99 read-only;
100 };
101
102 partition@50000 {
103 label = "devconf";
104 reg = <0x050000 0x010000>;
105 read-only;
106 };
107
108 partition@60000 {
109 label = "misc";
110 reg = <0x060000 0x010000>;
111 read-only;
112 };
113
114 partition@70000 {
115 label = "wifimngdata";
116 reg = <0x070000 0x010000>;
117 read-only;
118 };
119
120 partition@80000 {
121 compatible = "seama";
122 label = "firmware";
123 reg = <0x080000 0x770000>;
124 };
125
126 partition@7f0000 {
127 label = "art";
128 reg = <0x7f0000 0x010000>;
129 read-only;
130 };
131 };
132 };
133 };
134
135 &mdio0 {
136 status = "okay";
137
138 phy0: ethernet-phy@0 {
139 reg = <0>;
140
141 qca,ar8327-initvals = <
142 0x04 0x00000080 /* PORT0 PAD MODE CTRL */
143 0x50 0xcc35cc35 /* LED_CTRL0 */
144 0x54 0xca35ca35 /* LED_CTRL1 */
145 0x58 0xc935c935 /* LED_CTRL2 */
146 0x5c 0x03ffff00 /* LED_CTRL3 */
147 0x7c 0x0000007e /* PORT0_STATUS */
148 >;
149 };
150 };
151
152 &eth0 {
153 status = "okay";
154
155 pll-data = <0x03000101 0x00000101 0x00001919>;
156
157 phy-mode = "sgmii";
158 phy-handle = <&phy0>;
159 };
160
161 &pcie {
162 status = "okay";
163
164 wifi@0,0 {
165 compatible = "pci168c,0056";
166 reg = <0x0000 0 0 0 0>;
167 };
168 };
169
170 &uart {
171 status = "okay";
172 };
173
174 &wmac {
175 status = "okay";
176
177 qca,no-eeprom;
178 };