blob: 2a1d0dc87cef6b8409096cbe250a73edbe066c70 [file] [log] [blame]
developercd6a1382022-01-11 15:45:19 +08001/dts-v1/;
2#include "mt7986a.dtsi"
3#include "mt7986a-pinctrl.dtsi"
4/ {
5 model = "MediaTek MT7986a RFB";
6 compatible = "mediatek,mt7986a-2500wan-sd-rfb";
7 chosen {
8 bootargs = "console=ttyS0,115200n1 loglevel=8 \
9 earlycon=uart8250,mmio32,0x11002000 \
10 root=PARTLABEL=rootfs rootwait rootfstype=squashfs,f2fs";
11 };
12
13 memory {
14 reg = <0 0x40000000 0 0x10000000>;
15 };
16
17 sound {
18 compatible = "mediatek,mt7986-wm8960-machine";
19 mediatek,platform = <&afe>;
20 audio-routing = "Headphone", "HP_L",
21 "Headphone", "HP_R",
22 "LINPUT1", "AMIC",
23 "RINPUT1", "AMIC";
24 mediatek,audio-codec = <&wm8960>;
25 status = "okay";
26 };
27
28 reg_3p3v: regulator-3p3v {
29 compatible = "regulator-fixed";
30 regulator-name = "fixed-3.3V";
31 regulator-min-microvolt = <3300000>;
32 regulator-max-microvolt = <3300000>;
33 regulator-boot-on;
34 regulator-always-on;
35 };
36};
37
38&pwm {
39 pinctrl-names = "default";
40 pinctrl-0 = <&pwm0_pin &pwm1_pin_g1>;
41 status = "okay";
42};
43
44&uart0 {
45 status = "okay";
46};
47
48&uart1 {
49 pinctrl-names = "default";
50 pinctrl-0 = <&uart1_pins>;
51 status = "okay";
52};
53
54&uart2 {
55 pinctrl-names = "default";
56 pinctrl-0 = <&uart2_pins>;
57 status = "okay";
58};
59
60&i2c0 {
61 pinctrl-names = "default";
62 pinctrl-0 = <&i2c_pins>;
63 status = "okay";
64
65 wm8960: wm8960@1a {
66 compatible = "wlf,wm8960";
67 reg = <0x1a>;
68 };
69};
70
71&auxadc {
72 status = "okay";
73};
74
75&watchdog {
76 status = "okay";
77};
78
79&eth {
80 status = "okay";
81
82 gmac0: mac@0 {
83 compatible = "mediatek,eth-mac";
84 reg = <0>;
85 phy-mode = "2500base-x";
86
87 fixed-link {
88 speed = <2500>;
89 full-duplex;
90 pause;
91 };
92 };
93
94 gmac1: mac@1 {
95 compatible = "mediatek,eth-mac";
96 reg = <1>;
97 phy-mode = "2500base-x";
98
99 fixed-link {
100 speed = <2500>;
101 full-duplex;
102 pause;
103 };
104 };
105
106 mdio: mdio-bus {
107 #address-cells = <1>;
108 #size-cells = <0>;
109
110 phy5: phy@5 {
111 compatible = "ethernet-phy-id67c9.de0a";
112 reg = <5>;
113 reset-gpios = <&pio 6 1>;
114 reset-deassert-us = <20000>;
115 phy-mode = "2500base-x";
116 };
117
118 phy6: phy@6 {
119 compatible = "ethernet-phy-id67c9.de0a";
120 reg = <6>;
121 phy-mode = "2500base-x";
122 };
123
124 switch@0 {
125 compatible = "mediatek,mt7531";
126 reg = <31>;
127 reset-gpios = <&pio 5 0>;
128
129 ports {
130 #address-cells = <1>;
131 #size-cells = <0>;
132
133 port@0 {
134 reg = <0>;
135 label = "lan0";
136 };
137
138 port@1 {
139 reg = <1>;
140 label = "lan1";
141 };
142
143 port@2 {
144 reg = <2>;
145 label = "lan2";
146 };
147
148 port@3 {
149 reg = <3>;
150 label = "lan3";
151 };
152
153 port@4 {
154 reg = <4>;
155 label = "lan4";
156 };
157
158 port@5 {
159 reg = <5>;
160 label = "lan5";
161 phy-mode = "2500base-x";
162
163 fixed-link {
164 speed = <2500>;
165 full-duplex;
166 pause;
167 };
168 };
169
170 port@6 {
171 reg = <6>;
172 label = "cpu";
173 ethernet = <&gmac0>;
174 phy-mode = "2500base-x";
175
176 fixed-link {
177 speed = <2500>;
178 full-duplex;
179 pause;
180 };
181 };
182 };
183 };
184 };
185};
186
187&hnat {
188 mtketh-wan = "eth1";
189 mtketh-lan = "lan";
190 mtketh-max-gmac = <2>;
191 status = "okay";
192};
193
194&mmc0 {
195 pinctrl-names = "default", "state_uhs";
196 pinctrl-0 = <&mmc0_pins_default>;
197 pinctrl-1 = <&mmc0_pins_uhs>;
198 bus-width = <4>;
199 max-frequency = <52000000>;
200 cap-sd-highspeed;
201 vmmc-supply = <&reg_3p3v>;
202 vqmmc-supply = <&reg_3p3v>;
203 status = "okay";
204};
205
206&pcie0 {
207 pinctrl-names = "default";
208 pinctrl-0 = <&pcie0_pins>;
209 status = "okay";
210};
211
212&pio {
213 mmc0_pins_default: mmc0-pins-50-to-61-default {
214 mux {
215 function = "flash";
216 groups = "emmc_51";
217 };
218 conf-cmd-dat {
219 pins = "EMMC_DATA_0", "EMMC_DATA_1", "EMMC_DATA_2",
220 "EMMC_DATA_3", "EMMC_DATA_4", "EMMC_DATA_5",
221 "EMMC_DATA_6", "EMMC_DATA_7", "EMMC_CMD";
222 input-enable;
223 drive-strength = <MTK_DRIVE_4mA>;
224 mediatek,pull-up-adv = <1>; /* pull-up 10K */
225 };
226 conf-clk {
227 pins = "EMMC_CK";
228 drive-strength = <MTK_DRIVE_6mA>;
229 mediatek,pull-down-adv = <2>; /* pull-down 50K */
230 };
231 conf-ds {
232 pins = "EMMC_DSL";
233 mediatek,pull-down-adv = <2>; /* pull-down 50K */
234 };
235 conf-rst {
236 pins = "EMMC_RSTB";
237 drive-strength = <MTK_DRIVE_4mA>;
238 mediatek,pull-up-adv = <1>; /* pull-up 10K */
239 };
240 };
241
242 mmc0_pins_uhs: mmc0-pins-50-to-61-uhs {
243 mux {
244 function = "flash";
245 groups = "emmc_51";
246 };
247 conf-cmd-dat {
248 pins = "EMMC_DATA_0", "EMMC_DATA_1", "EMMC_DATA_2",
249 "EMMC_DATA_3", "EMMC_DATA_4", "EMMC_DATA_5",
250 "EMMC_DATA_6", "EMMC_DATA_7", "EMMC_CMD";
251 input-enable;
252 drive-strength = <MTK_DRIVE_4mA>;
253 mediatek,pull-up-adv = <1>; /* pull-up 10K */
254 };
255 conf-clk {
256 pins = "EMMC_CK";
257 drive-strength = <MTK_DRIVE_6mA>;
258 mediatek,pull-down-adv = <2>; /* pull-down 50K */
259 };
260 conf-ds {
261 pins = "EMMC_DSL";
262 mediatek,pull-down-adv = <2>; /* pull-down 50K */
263 };
264 conf-rst {
265 pins = "EMMC_RSTB";
266 drive-strength = <MTK_DRIVE_4mA>;
267 mediatek,pull-up-adv = <1>; /* pull-up 10K */
268 };
269 };
270
271 wf_2g_5g_pins: wf_2g_5g-pins {
272 mux {
273 function = "wifi";
274 groups = "wf_2g", "wf_5g";
275 };
276 conf {
277 pins = "WF0_HB1", "WF0_HB2", "WF0_HB3", "WF0_HB4",
278 "WF0_HB0", "WF0_HB0_B", "WF0_HB5", "WF0_HB6",
279 "WF0_HB7", "WF0_HB8", "WF0_HB9", "WF0_HB10",
280 "WF0_TOP_CLK", "WF0_TOP_DATA", "WF1_HB1",
281 "WF1_HB2", "WF1_HB3", "WF1_HB4", "WF1_HB0",
282 "WF1_HB5", "WF1_HB6", "WF1_HB7", "WF1_HB8",
283 "WF1_TOP_CLK", "WF1_TOP_DATA";
284 drive-strength = <MTK_DRIVE_4mA>;
285 };
286 };
287
288 wf_dbdc_pins: wf_dbdc-pins {
289 mux {
290 function = "wifi";
291 groups = "wf_dbdc";
292 };
293 conf {
294 pins = "WF0_HB1", "WF0_HB2", "WF0_HB3", "WF0_HB4",
295 "WF0_HB0", "WF0_HB0_B", "WF0_HB5", "WF0_HB6",
296 "WF0_HB7", "WF0_HB8", "WF0_HB9", "WF0_HB10",
297 "WF0_TOP_CLK", "WF0_TOP_DATA", "WF1_HB1",
298 "WF1_HB2", "WF1_HB3", "WF1_HB4", "WF1_HB0",
299 "WF1_HB5", "WF1_HB6", "WF1_HB7", "WF1_HB8",
300 "WF1_TOP_CLK", "WF1_TOP_DATA";
301 drive-strength = <MTK_DRIVE_4mA>;
302 };
303 };
304};