Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 1 | // SPDX-License-Identifier: (GPL-2.0+ OR MIT) |
2 | /* | ||||
3 | * Copyright 2022 Gateworks Corporation | ||||
4 | */ | ||||
5 | |||||
6 | #include "imx8mp-u-boot.dtsi" | ||||
7 | |||||
8 | / { | ||||
9 | firmware { | ||||
10 | optee { | ||||
11 | compatible = "linaro,optee-tz"; | ||||
12 | method = "smc"; | ||||
13 | }; | ||||
14 | }; | ||||
15 | |||||
16 | wdt-reboot { | ||||
17 | compatible = "wdt-reboot"; | ||||
Simon Glass | d3a98cb | 2023-02-13 08:56:33 -0700 | [diff] [blame] | 18 | bootph-pre-ram; |
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 19 | wdt = <&wdog1>; |
20 | }; | ||||
21 | }; | ||||
22 | |||||
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 23 | ðphy0 { |
24 | reset-gpios = <&gpio4 30 GPIO_ACTIVE_LOW>; | ||||
25 | reset-delay-us = <1000>; | ||||
26 | reset-post-delay-us = <300000>; | ||||
27 | }; | ||||
28 | |||||
29 | &fec { | ||||
30 | phy-reset-gpios = <&gpio4 29 GPIO_ACTIVE_LOW>; | ||||
31 | phy-reset-duration = <15>; | ||||
32 | phy-reset-post-delay = <100>; | ||||
33 | }; | ||||
34 | |||||
35 | &gpio1 { | ||||
Simon Glass | d3a98cb | 2023-02-13 08:56:33 -0700 | [diff] [blame] | 36 | bootph-pre-ram; |
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 37 | |
38 | dio0_hog { | ||||
39 | gpio-hog; | ||||
40 | input; | ||||
41 | gpios = <9 GPIO_ACTIVE_LOW>; | ||||
42 | line-name = "dio0"; | ||||
43 | }; | ||||
44 | |||||
45 | dio1_hog { | ||||
46 | gpio-hog; | ||||
47 | input; | ||||
48 | gpios = <11 GPIO_ACTIVE_LOW>; | ||||
49 | line-name = "dio1"; | ||||
50 | }; | ||||
51 | }; | ||||
52 | |||||
53 | &gpio2 { | ||||
Simon Glass | d3a98cb | 2023-02-13 08:56:33 -0700 | [diff] [blame] | 54 | bootph-pre-ram; |
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 55 | |
Tim Harvey | ffe9e3c | 2023-08-15 15:01:15 -0700 | [diff] [blame^] | 56 | m2_pin20 { |
57 | gpio-hog; | ||||
58 | input; | ||||
59 | gpios = <6 GPIO_ACTIVE_HIGH>; | ||||
60 | line-name = "m2_pin20"; | ||||
61 | }; | ||||
62 | |||||
63 | m2_pin22 { | ||||
64 | gpio-hog; | ||||
65 | input; | ||||
66 | gpios = <11 GPIO_ACTIVE_HIGH>; | ||||
67 | line-name = "m2_pin22"; | ||||
68 | }; | ||||
69 | |||||
70 | tpm_rst_hog { | ||||
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 71 | gpio-hog; |
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 72 | output-high; |
Tim Harvey | ffe9e3c | 2023-08-15 15:01:15 -0700 | [diff] [blame^] | 73 | gpios = <12 GPIO_ACTIVE_HIGH>; |
74 | line-name = "tpm_rst#"; | ||||
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 75 | }; |
76 | |||||
Tim Harvey | ffe9e3c | 2023-08-15 15:01:15 -0700 | [diff] [blame^] | 77 | pcie1_wdis_hog { |
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 78 | gpio-hog; |
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 79 | output-high; |
Tim Harvey | ffe9e3c | 2023-08-15 15:01:15 -0700 | [diff] [blame^] | 80 | gpios = <13 GPIO_ACTIVE_HIGH>; |
81 | line-name = "pcie1_wdis#"; | ||||
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 82 | }; |
83 | |||||
84 | pcie3_wdis_hog { | ||||
85 | gpio-hog; | ||||
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 86 | output-high; |
Tim Harvey | ffe9e3c | 2023-08-15 15:01:15 -0700 | [diff] [blame^] | 87 | gpios = <14 GPIO_ACTIVE_HIGH>; |
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 88 | line-name = "pcie3_wdis#"; |
89 | }; | ||||
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 90 | |
Tim Harvey | ffe9e3c | 2023-08-15 15:01:15 -0700 | [diff] [blame^] | 91 | pcie2_wdis_hog { |
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 92 | gpio-hog; |
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 93 | output-high; |
Tim Harvey | ffe9e3c | 2023-08-15 15:01:15 -0700 | [diff] [blame^] | 94 | gpios = <18 GPIO_ACTIVE_HIGH>; |
95 | line-name = "pcie2_wdis#"; | ||||
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 96 | }; |
Tim Harvey | ffe9e3c | 2023-08-15 15:01:15 -0700 | [diff] [blame^] | 97 | }; |
98 | |||||
99 | &gpio3 { | ||||
100 | bootph-pre-ram; | ||||
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 101 | |
Tim Harvey | ffe9e3c | 2023-08-15 15:01:15 -0700 | [diff] [blame^] | 102 | m2_rst { |
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 103 | gpio-hog; |
Tim Harvey | ffe9e3c | 2023-08-15 15:01:15 -0700 | [diff] [blame^] | 104 | output-low; |
Tim Harvey | feb2267 | 2022-09-08 13:42:01 -0700 | [diff] [blame] | 105 | gpios = <6 GPIO_ACTIVE_HIGH>; |
Tim Harvey | ffe9e3c | 2023-08-15 15:01:15 -0700 | [diff] [blame^] | 106 | line-name = "m2_rst"; |
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 107 | }; |
Tim Harvey | ffe9e3c | 2023-08-15 15:01:15 -0700 | [diff] [blame^] | 108 | }; |
109 | |||||
110 | &gpio4 { | ||||
111 | bootph-pre-ram; | ||||
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 112 | |
Tim Harvey | ffe9e3c | 2023-08-15 15:01:15 -0700 | [diff] [blame^] | 113 | m2_off { |
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 114 | gpio-hog; |
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 115 | output-high; |
Tim Harvey | ffe9e3c | 2023-08-15 15:01:15 -0700 | [diff] [blame^] | 116 | gpios = <2 GPIO_ACTIVE_HIGH>; |
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 117 | line-name = "m2_off#"; |
118 | }; | ||||
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 119 | |
Tim Harvey | ffe9e3c | 2023-08-15 15:01:15 -0700 | [diff] [blame^] | 120 | m2_wdis { |
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 121 | gpio-hog; |
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 122 | output-high; |
Tim Harvey | ffe9e3c | 2023-08-15 15:01:15 -0700 | [diff] [blame^] | 123 | gpios = <18 GPIO_ACTIVE_HIGH>; |
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 124 | line-name = "m2_wdis#"; |
125 | }; | ||||
126 | |||||
Tim Harvey | eb7878b | 2022-09-08 13:41:08 -0700 | [diff] [blame] | 127 | rs485_en { |
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 128 | gpio-hog; |
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 129 | output-low; |
Tim Harvey | ffe9e3c | 2023-08-15 15:01:15 -0700 | [diff] [blame^] | 130 | gpios = <31 GPIO_ACTIVE_HIGH>; |
Tim Harvey | eb7878b | 2022-09-08 13:41:08 -0700 | [diff] [blame] | 131 | line-name = "rs485_en"; |
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 132 | }; |
133 | }; | ||||
134 | |||||
135 | &gpio5 { | ||||
Simon Glass | d3a98cb | 2023-02-13 08:56:33 -0700 | [diff] [blame] | 136 | bootph-pre-ram; |
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 137 | |
Tim Harvey | eb7878b | 2022-09-08 13:41:08 -0700 | [diff] [blame] | 138 | rs485_half { |
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 139 | gpio-hog; |
Tim Harvey | eb7878b | 2022-09-08 13:41:08 -0700 | [diff] [blame] | 140 | output-low; |
Tim Harvey | ffe9e3c | 2023-08-15 15:01:15 -0700 | [diff] [blame^] | 141 | gpios = <0 GPIO_ACTIVE_HIGH>; |
Tim Harvey | eb7878b | 2022-09-08 13:41:08 -0700 | [diff] [blame] | 142 | line-name = "rs485_hd"; |
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 143 | }; |
144 | |||||
Tim Harvey | eb7878b | 2022-09-08 13:41:08 -0700 | [diff] [blame] | 145 | rs485_term { |
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 146 | gpio-hog; |
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 147 | output-low; |
Tim Harvey | ffe9e3c | 2023-08-15 15:01:15 -0700 | [diff] [blame^] | 148 | gpios = <1 GPIO_ACTIVE_HIGH>; |
Tim Harvey | eb7878b | 2022-09-08 13:41:08 -0700 | [diff] [blame] | 149 | line-name = "rs485_term"; |
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 150 | }; |
151 | }; | ||||
152 | |||||
153 | &i2c1 { | ||||
Simon Glass | d3a98cb | 2023-02-13 08:56:33 -0700 | [diff] [blame] | 154 | bootph-pre-ram; |
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 155 | }; |
156 | |||||
157 | &i2c2 { | ||||
Simon Glass | d3a98cb | 2023-02-13 08:56:33 -0700 | [diff] [blame] | 158 | bootph-pre-ram; |
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 159 | }; |
160 | |||||
161 | &i2c3 { | ||||
Simon Glass | d3a98cb | 2023-02-13 08:56:33 -0700 | [diff] [blame] | 162 | bootph-pre-ram; |
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 163 | }; |
164 | |||||
165 | &pinctrl_i2c1 { | ||||
Simon Glass | d3a98cb | 2023-02-13 08:56:33 -0700 | [diff] [blame] | 166 | bootph-pre-ram; |
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 167 | }; |
168 | |||||
169 | &pinctrl_wdog { | ||||
Simon Glass | d3a98cb | 2023-02-13 08:56:33 -0700 | [diff] [blame] | 170 | bootph-pre-ram; |
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 171 | }; |
172 | |||||
Tim Harvey | 4475450 | 2022-09-09 14:42:11 -0700 | [diff] [blame] | 173 | &switch { |
174 | ports { | ||||
175 | #address-cells = <1>; | ||||
176 | #size-cells = <0>; | ||||
177 | |||||
178 | lan1: port@0 { | ||||
179 | phy-handle = <&sw_phy0>; | ||||
180 | }; | ||||
181 | |||||
182 | lan2: port@1 { | ||||
183 | phy-handle = <&sw_phy1>; | ||||
184 | }; | ||||
185 | |||||
186 | lan3: port@2 { | ||||
187 | phy-handle = <&sw_phy2>; | ||||
188 | }; | ||||
189 | |||||
190 | lan4: port@3 { | ||||
191 | phy-handle = <&sw_phy3>; | ||||
192 | }; | ||||
193 | |||||
194 | lan5: port@4 { | ||||
195 | phy-handle = <&sw_phy4>; | ||||
196 | }; | ||||
197 | }; | ||||
198 | |||||
199 | mdios { | ||||
200 | #address-cells = <1>; | ||||
201 | #size-cells = <0>; | ||||
202 | |||||
203 | mdio@0 { | ||||
204 | reg = <0>; | ||||
205 | compatible = "microchip,ksz-mdio"; | ||||
206 | #address-cells = <1>; | ||||
207 | #size-cells = <0>; | ||||
208 | |||||
209 | sw_phy0: ethernet-phy@0 { | ||||
210 | reg = <0x0>; | ||||
211 | }; | ||||
212 | |||||
213 | sw_phy1: ethernet-phy@1 { | ||||
214 | reg = <0x1>; | ||||
215 | }; | ||||
216 | |||||
217 | sw_phy2: ethernet-phy@2 { | ||||
218 | reg = <0x2>; | ||||
219 | }; | ||||
220 | |||||
221 | sw_phy3: ethernet-phy@3 { | ||||
222 | reg = <0x3>; | ||||
223 | }; | ||||
224 | |||||
225 | sw_phy4: ethernet-phy@4 { | ||||
226 | reg = <0x4>; | ||||
227 | }; | ||||
228 | }; | ||||
229 | }; | ||||
230 | }; | ||||
231 | |||||
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 232 | &usdhc2 { |
233 | assigned-clock-parents = <&clk IMX8MP_SYS_PLL1_400M>; | ||||
234 | assigned-clock-rates = <400000000>; | ||||
235 | assigned-clocks = <&clk IMX8MP_CLK_USDHC2>; | ||||
236 | sd-uhs-ddr50; | ||||
237 | sd-uhs-sdr104; | ||||
Simon Glass | d3a98cb | 2023-02-13 08:56:33 -0700 | [diff] [blame] | 238 | bootph-pre-ram; |
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 239 | }; |
240 | |||||
241 | &usdhc3 { | ||||
242 | assigned-clock-parents = <&clk IMX8MP_SYS_PLL1_400M>; | ||||
243 | assigned-clock-rates = <400000000>; | ||||
244 | assigned-clocks = <&clk IMX8MP_CLK_USDHC3>; | ||||
245 | mmc-hs400-1_8v; | ||||
246 | mmc-hs400-enhanced-strobe; | ||||
Simon Glass | d3a98cb | 2023-02-13 08:56:33 -0700 | [diff] [blame] | 247 | bootph-pre-ram; |
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 248 | }; |
249 | |||||
250 | &wdog1 { | ||||
Simon Glass | d3a98cb | 2023-02-13 08:56:33 -0700 | [diff] [blame] | 251 | bootph-pre-ram; |
Tim Harvey | 0f5717f | 2022-04-13 11:31:09 -0700 | [diff] [blame] | 252 | }; |