ipq806x: fix Linksys EAX500 family devices dead Ethernet switch
[openwrt/staging/aparcar.git] / target / linux / ipq806x / files-5.10 / arch / arm / boot / dts / qcom-ipq8064-eax500.dtsi
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2
3 #include "qcom-ipq8064-v2.0.dtsi"
4
5 #include <dt-bindings/input/input.h>
6
7 / {
8 chosen {
9 bootargs = "console=ttyMSM0,115200n8";
10 /* append to bootargs adding the root deviceblock nbr from bootloader */
11 append-rootblock = "ubi.mtd=";
12 };
13 };
14
15 &qcom_pinmux {
16 /* eax500 routers reuse the pcie2 reset pin for switch reset pin */
17 switch_reset: switch_reset_pins {
18 mux {
19 pins = "gpio63";
20 function = "gpio";
21 drive-strength = <12>;
22 bias-pull-up;
23 };
24 };
25 };
26
27 &usb3_0 {
28 status = "okay";
29 };
30
31 &usb3_1 {
32 status = "okay";
33 };
34
35 &pcie0 {
36 status = "okay";
37
38 max-link-speed = <1>;
39 };
40
41 &pcie1 {
42 status = "okay";
43 };
44
45 &nand {
46 status = "okay";
47
48 pinctrl-0 = <&nand_pins>;
49 pinctrl-names = "default";
50
51 nand@0 {
52 reg = <0>;
53 compatible = "qcom,nandcs";
54
55 nand-ecc-strength = <4>;
56 nand-bus-width = <8>;
57 nand-ecc-step-size = <512>;
58
59 nand-is-boot-medium;
60 qcom,boot_pages_size = <0x0c80000>;
61
62 partitions: partitions {
63 compatible = "fixed-partitions";
64 #address-cells = <1>;
65 #size-cells = <1>;
66
67 partition@0 {
68 label = "SBL1";
69 reg = <0x0000000 0x0040000>;
70 read-only;
71 };
72
73 partition@40000 {
74 label = "MIBIB";
75 reg = <0x0040000 0x0140000>;
76 read-only;
77 };
78
79 partition@180000 {
80 label = "SBL2";
81 reg = <0x0180000 0x0140000>;
82 read-only;
83 };
84
85 partition@2c0000 {
86 label = "SBL3";
87 reg = <0x02c0000 0x0280000>;
88 read-only;
89 };
90
91 partition@540000 {
92 label = "DDRCONFIG";
93 reg = <0x0540000 0x0120000>;
94 read-only;
95 };
96
97 partition@660000 {
98 label = "SSD";
99 reg = <0x0660000 0x0120000>;
100 read-only;
101 };
102
103 partition@780000 {
104 label = "TZ";
105 reg = <0x0780000 0x0280000>;
106 read-only;
107 };
108
109 partition@a00000 {
110 label = "RPM";
111 reg = <0x0a00000 0x0280000>;
112 read-only;
113 };
114
115 art: partition@c80000 {
116 label = "art";
117 reg = <0x0c80000 0x0140000>;
118 read-only;
119 };
120
121 partition@dc0000 {
122 label = "APPSBL";
123 reg = <0x0dc0000 0x0100000>;
124 read-only;
125 };
126
127 partition@ec0000 {
128 label = "u_env";
129 reg = <0x0ec0000 0x0040000>;
130 };
131
132 partition@f00000 {
133 label = "s_env";
134 reg = <0x0f00000 0x0040000>;
135 };
136
137 partition@f40000 {
138 label = "devinfo";
139 reg = <0x0f40000 0x0040000>;
140 };
141
142 partition@f80000 {
143 label = "kernel1";
144 reg = <0x0f80000 0x2800000>; /* 4 MB, spill to rootfs */
145 };
146
147 partition@1380000 {
148 label = "rootfs1";
149 reg = <0x1380000 0x2400000>;
150 };
151
152 partition@3780000 {
153 label = "kernel2";
154 reg = <0x3780000 0x2800000>;
155 };
156
157 partition@3b80000 {
158 label = "rootfs2";
159 reg = <0x3b80000 0x2400000>;
160 };
161 };
162 };
163 };
164
165 &mdio0 {
166 status = "okay";
167
168 pinctrl-0 = <&mdio0_pins>;
169 pinctrl-names = "default";
170
171 /* Switch from documentation require at least 10ms for reset */
172 reset-gpios = <&qcom_pinmux 63 GPIO_ACTIVE_HIGH>;
173 reset-post-delay-us = <12000>;
174
175 phy0: ethernet-phy@0 {
176 reg = <0>;
177 qca,ar8327-initvals = <
178 0x00004 0x7600000 /* PAD0_MODE */
179 0x00008 0x1000000 /* PAD5_MODE */
180 0x0000c 0x80 /* PAD6_MODE */
181 0x00010 0x2613a0 /* PWS_REG */
182 0x000e4 0x6a545 /* MAC_POWER_SEL */
183 0x000e0 0xc74164de /* SGMII_CTRL */
184 0x0007c 0x4e /* PORT0_STATUS */
185 0x00094 0x4e /* PORT6_STATUS */
186 >;
187 };
188 };
189
190 &gmac1 {
191 status = "okay";
192
193 phy-mode = "rgmii";
194 qcom,id = <1>;
195
196 pinctrl-0 = <&rgmii2_pins>;
197 pinctrl-names = "default";
198
199 fixed-link {
200 speed = <1000>;
201 full-duplex;
202 };
203 };
204
205 &gmac2 {
206 status = "okay";
207
208 phy-mode = "sgmii";
209 qcom,id = <2>;
210
211 fixed-link {
212 speed = <1000>;
213 full-duplex;
214 };
215 };
216
217 &adm_dma {
218 status = "okay";
219 };