blob: 3f54411b7b33d3262a27b4cacc048de3dba8a600 [file] [log] [blame]
Giulio Benetti6986d6b2020-01-10 15:51:48 +01001// SPDX-License-Identifier: (GPL-2.0+ OR BSD-3-Clause)
2/*
3 * Copyright (C) 2019
4 * Author(s): Giulio Benetti <giulio.benetti@benettiengineering.com>
5 */
6
Marcel Ziswiler118ad852022-11-07 22:22:36 +01007#include <dt-bindings/memory/imxrt-sdram.h>
8#include "imxrt1050-pinfunc.h"
9
Giulio Benetti6986d6b2020-01-10 15:51:48 +010010/ {
Jesse Taube9fcbb552024-02-19 18:00:59 -050011 binman: binman {
12 multiple-images;
13 };
14
Marcel Ziswiler118ad852022-11-07 22:22:36 +010015 aliases {
16 display0 = &lcdif;
17 usbphy0 = &usbphy1;
18 };
19
Giulio Benetti6986d6b2020-01-10 15:51:48 +010020 chosen {
Simon Glassd3a98cb2023-02-13 08:56:33 -070021 bootph-pre-ram;
Marcel Ziswiler118ad852022-11-07 22:22:36 +010022 tick-timer = &gpt;
Giulio Benetti6986d6b2020-01-10 15:51:48 +010023 };
Giulio Benettia8695632021-05-16 23:57:00 +020024
25 clocks {
Simon Glassd3a98cb2023-02-13 08:56:33 -070026 bootph-pre-ram;
Giulio Benettia8695632021-05-16 23:57:00 +020027 };
28
29 soc {
Simon Glassd3a98cb2023-02-13 08:56:33 -070030 bootph-pre-ram;
Marcel Ziswiler118ad852022-11-07 22:22:36 +010031
32 usbphy1: usbphy@400d9000 {
33 compatible = "fsl,imxrt-usbphy";
34 reg = <0x400d9000 0x1000>;
35 interrupts = <GIC_SPI 65 IRQ_TYPE_LEVEL_HIGH>;
36 };
37
38 usbmisc: usbmisc@402e0800 {
39 #index-cells = <1>;
40 compatible = "fsl,imxrt-usbmisc";
41 reg = <0x402e0800 0x200>;
42 clocks = <&clks IMXRT1050_CLK_USBOH3>;
43 };
44
45 usbotg1: usb@402e0000 {
46 compatible = "fsl,imxrt-usb", "fsl,imx27-usb";
47 reg = <0x402e0000 0x200>;
48 interrupts = <GIC_SPI 113 IRQ_TYPE_LEVEL_HIGH>;
49 clocks = <&clks IMXRT1050_CLK_USBOH3>;
50 fsl,usbphy = <&usbphy1>;
51 fsl,usbmisc = <&usbmisc 0>;
52 ahb-burst-config = <0x0>;
53 tx-burst-size-dword = <0x10>;
54 rx-burst-size-dword = <0x10>;
55 status = "disabled";
56 };
57
58 lcdif: lcdif@402b8000 {
59 compatible = "fsl,imxrt-lcdif";
60 reg = <0x402b8000 0x4000>;
61 interrupts = <GIC_SPI 42 IRQ_TYPE_LEVEL_HIGH>;
62 clocks = <&clks IMXRT1050_CLK_LCDIF_PIX>,
63 <&clks IMXRT1050_CLK_LCDIF_APB>;
64 clock-names = "pix", "axi";
65 assigned-clocks = <&clks IMXRT1050_CLK_LCDIF_SEL>;
66 assigned-clock-parents = <&clks IMXRT1050_CLK_PLL5_VIDEO>;
67 status = "disabled";
68 };
69
70 semc: semc@402f0000 {
71 compatible = "fsl,imxrt-semc";
72 reg = <0x402f0000 0x4000>;
73 clocks = <&clks IMXRT1050_CLK_SEMC>;
74 pinctrl-0 = <&pinctrl_semc>;
75 pinctrl-names = "default";
76 status = "okay";
77 };
Giulio Benettia8695632021-05-16 23:57:00 +020078 };
Giulio Benetti6986d6b2020-01-10 15:51:48 +010079};
80
Marcel Ziswiler118ad852022-11-07 22:22:36 +010081&semc {
Simon Glassd3a98cb2023-02-13 08:56:33 -070082 bootph-pre-ram;
Marcel Ziswiler118ad852022-11-07 22:22:36 +010083 /*
84 * Memory configuration from sdram datasheet IS42S16160J-6BLI
85 */
86 fsl,sdram-mux = /bits/ 8 <MUX_A8_SDRAM_A8
87 MUX_CSX0_SDRAM_CS1
88 0
89 0
90 0
91 0>;
92 fsl,sdram-control = /bits/ 8 <MEM_WIDTH_16BITS
93 BL_8
94 COL_9BITS
95 CL_3>;
96 fsl,sdram-timing = /bits/ 8 <0x2
97 0x2
98 0x9
99 0x1
100 0x5
101 0x6
102
103 0x20
104 0x09
105 0x01
106 0x00
107
108 0x04
109 0x0A
110 0x21
111 0x50>;
112
113 bank1: bank@0 {
114 fsl,base-address = <0x80000000>;
115 fsl,memory-size = <MEM_SIZE_32M>;
Simon Glassd3a98cb2023-02-13 08:56:33 -0700116 bootph-pre-ram;
Marcel Ziswiler118ad852022-11-07 22:22:36 +0100117 };
Jesse Taube9fcbb552024-02-19 18:00:59 -0500118};
119
120&binman {
121#ifdef CONFIG_FSPI_CONF_HEADER
122 imx-boot {
123 filename = "flash.bin";
124 pad-byte = <0x00>;
125
126 fspi_conf_block {
127 filename = CONFIG_FSPI_CONF_FILE;
128 type = "blob-ext";
129 offset = <0x0>;
130 };
131
132 spl {
133 filename = "SPL";
134 offset = <0x1000>;
135 type = "blob-ext";
136 };
137
138 binman_uboot: uboot {
139 filename = "u-boot.img";
140 offset = <0x10000>;
141 type = "blob-ext";
142 };
143 };
144#endif
Marcel Ziswiler118ad852022-11-07 22:22:36 +0100145};
146
Giulio Benettia8695632021-05-16 23:57:00 +0200147&osc {
Simon Glassd3a98cb2023-02-13 08:56:33 -0700148 bootph-pre-ram;
Giulio Benettia8695632021-05-16 23:57:00 +0200149};
150
Jesse Taube214f4432022-03-17 14:33:18 -0400151&anatop {
Simon Glassd3a98cb2023-02-13 08:56:33 -0700152 bootph-pre-ram;
Jesse Taube214f4432022-03-17 14:33:18 -0400153};
154
Giulio Benettia8695632021-05-16 23:57:00 +0200155&clks {
Simon Glassd3a98cb2023-02-13 08:56:33 -0700156 bootph-pre-ram;
Giulio Benettia8695632021-05-16 23:57:00 +0200157};
158
159&gpio1 {
Marcel Ziswiler118ad852022-11-07 22:22:36 +0100160 compatible = "fsl,imxrt-gpio", "fsl,imx35-gpio";
Simon Glassd3a98cb2023-02-13 08:56:33 -0700161 bootph-pre-ram;
Giulio Benettia8695632021-05-16 23:57:00 +0200162};
163
164&gpio2 {
Marcel Ziswiler118ad852022-11-07 22:22:36 +0100165 compatible = "fsl,imxrt-gpio", "fsl,imx35-gpio";
Simon Glassd3a98cb2023-02-13 08:56:33 -0700166 bootph-pre-ram;
Giulio Benettia8695632021-05-16 23:57:00 +0200167};
168
169&gpio3 {
Marcel Ziswiler118ad852022-11-07 22:22:36 +0100170 compatible = "fsl,imxrt-gpio", "fsl,imx35-gpio";
Simon Glassd3a98cb2023-02-13 08:56:33 -0700171 bootph-pre-ram;
Giulio Benettia8695632021-05-16 23:57:00 +0200172};
173
174&gpio4 {
Marcel Ziswiler118ad852022-11-07 22:22:36 +0100175 compatible = "fsl,imxrt-gpio", "fsl,imx35-gpio";
Simon Glassd3a98cb2023-02-13 08:56:33 -0700176 bootph-pre-ram;
Giulio Benettia8695632021-05-16 23:57:00 +0200177};
178
179&gpio5 {
Marcel Ziswiler118ad852022-11-07 22:22:36 +0100180 compatible = "fsl,imxrt-gpio", "fsl,imx35-gpio";
Simon Glassd3a98cb2023-02-13 08:56:33 -0700181 bootph-pre-ram;
Giulio Benettia8695632021-05-16 23:57:00 +0200182};
183
Marcel Ziswiler118ad852022-11-07 22:22:36 +0100184&gpt {
185 clocks = <&osc>;
186 compatible = "fsl,imxrt-gpt";
187 status = "okay";
Simon Glassd3a98cb2023-02-13 08:56:33 -0700188 bootph-pre-ram;
Giulio Benettie4806ec2021-05-13 12:18:43 +0200189};
190
Giulio Benetti6986d6b2020-01-10 15:51:48 +0100191&lpuart1 { /* console */
Marcel Ziswiler118ad852022-11-07 22:22:36 +0100192 compatible = "fsl,imxrt-lpuart";
193 clock-names = "per";
Simon Glassd3a98cb2023-02-13 08:56:33 -0700194 bootph-pre-ram;
Giulio Benetti6986d6b2020-01-10 15:51:48 +0100195};
196
Marcel Ziswiler118ad852022-11-07 22:22:36 +0100197&iomuxc {
Simon Glassd3a98cb2023-02-13 08:56:33 -0700198 bootph-pre-ram;
Marcel Ziswiler118ad852022-11-07 22:22:36 +0100199 compatible = "fsl,imxrt-iomuxc";
200 pinctrl-0 = <&pinctrl_lpuart1>;
Giulio Benettia8695632021-05-16 23:57:00 +0200201
Marcel Ziswiler118ad852022-11-07 22:22:36 +0100202 pinctrl_semc: semcgrp {
203 fsl,pins = <
204 MXRT1050_IOMUXC_GPIO_EMC_00_SEMC_DA00
205 0xf1 /* SEMC_D0 */
206 MXRT1050_IOMUXC_GPIO_EMC_01_SEMC_DA01
207 0xf1 /* SEMC_D1 */
208 MXRT1050_IOMUXC_GPIO_EMC_02_SEMC_DA02
209 0xf1 /* SEMC_D2 */
210 MXRT1050_IOMUXC_GPIO_EMC_03_SEMC_DA03
211 0xf1 /* SEMC_D3 */
212 MXRT1050_IOMUXC_GPIO_EMC_04_SEMC_DA04
213 0xf1 /* SEMC_D4 */
214 MXRT1050_IOMUXC_GPIO_EMC_05_SEMC_DA05
215 0xf1 /* SEMC_D5 */
216 MXRT1050_IOMUXC_GPIO_EMC_06_SEMC_DA06
217 0xf1 /* SEMC_D6 */
218 MXRT1050_IOMUXC_GPIO_EMC_07_SEMC_DA07
219 0xf1 /* SEMC_D7 */
220 MXRT1050_IOMUXC_GPIO_EMC_08_SEMC_DM00
221 0xf1 /* SEMC_DM0 */
222 MXRT1050_IOMUXC_GPIO_EMC_09_SEMC_ADDR00
223 0xf1 /* SEMC_A0 */
224 MXRT1050_IOMUXC_GPIO_EMC_10_SEMC_ADDR01
225 0xf1 /* SEMC_A1 */
226 MXRT1050_IOMUXC_GPIO_EMC_11_SEMC_ADDR02
227 0xf1 /* SEMC_A2 */
228 MXRT1050_IOMUXC_GPIO_EMC_12_SEMC_ADDR03
229 0xf1 /* SEMC_A3 */
230 MXRT1050_IOMUXC_GPIO_EMC_13_SEMC_ADDR04
231 0xf1 /* SEMC_A4 */
232 MXRT1050_IOMUXC_GPIO_EMC_14_SEMC_ADDR05
233 0xf1 /* SEMC_A5 */
234 MXRT1050_IOMUXC_GPIO_EMC_15_SEMC_ADDR06
235 0xf1 /* SEMC_A6 */
236 MXRT1050_IOMUXC_GPIO_EMC_16_SEMC_ADDR07
237 0xf1 /* SEMC_A7 */
238 MXRT1050_IOMUXC_GPIO_EMC_17_SEMC_ADDR08
239 0xf1 /* SEMC_A8 */
240 MXRT1050_IOMUXC_GPIO_EMC_18_SEMC_ADDR09
241 0xf1 /* SEMC_A9 */
242 MXRT1050_IOMUXC_GPIO_EMC_19_SEMC_ADDR11
243 0xf1 /* SEMC_A11 */
244 MXRT1050_IOMUXC_GPIO_EMC_20_SEMC_ADDR12
245 0xf1 /* SEMC_A12 */
246 MXRT1050_IOMUXC_GPIO_EMC_21_SEMC_BA0
247 0xf1 /* SEMC_BA0 */
248 MXRT1050_IOMUXC_GPIO_EMC_22_SEMC_BA1
249 0xf1 /* SEMC_BA1 */
250 MXRT1050_IOMUXC_GPIO_EMC_23_SEMC_ADDR10
251 0xf1 /* SEMC_A10 */
252 MXRT1050_IOMUXC_GPIO_EMC_24_SEMC_CAS
253 0xf1 /* SEMC_CAS */
254 MXRT1050_IOMUXC_GPIO_EMC_25_SEMC_RAS
255 0xf1 /* SEMC_RAS */
256 MXRT1050_IOMUXC_GPIO_EMC_26_SEMC_CLK
257 0xf1 /* SEMC_CLK */
258 MXRT1050_IOMUXC_GPIO_EMC_27_SEMC_CKE
259 0xf1 /* SEMC_CKE */
260 MXRT1050_IOMUXC_GPIO_EMC_28_SEMC_WE
261 0xf1 /* SEMC_WE */
262 MXRT1050_IOMUXC_GPIO_EMC_29_SEMC_CS0
263 0xf1 /* SEMC_CS0 */
264 MXRT1050_IOMUXC_GPIO_EMC_30_SEMC_DA08
265 0xf1 /* SEMC_D8 */
266 MXRT1050_IOMUXC_GPIO_EMC_31_SEMC_DA09
267 0xf1 /* SEMC_D9 */
268 MXRT1050_IOMUXC_GPIO_EMC_32_SEMC_DA10
269 0xf1 /* SEMC_D10 */
270 MXRT1050_IOMUXC_GPIO_EMC_33_SEMC_DA11
271 0xf1 /* SEMC_D11 */
272 MXRT1050_IOMUXC_GPIO_EMC_34_SEMC_DA12
273 0xf1 /* SEMC_D12 */
274 MXRT1050_IOMUXC_GPIO_EMC_35_SEMC_DA13
275 0xf1 /* SEMC_D13 */
276 MXRT1050_IOMUXC_GPIO_EMC_36_SEMC_DA14
277 0xf1 /* SEMC_D14 */
278 MXRT1050_IOMUXC_GPIO_EMC_37_SEMC_DA15
279 0xf1 /* SEMC_D15 */
280 MXRT1050_IOMUXC_GPIO_EMC_38_SEMC_DM01
281 0xf1 /* SEMC_DM1 */
282 MXRT1050_IOMUXC_GPIO_EMC_39_SEMC_DQS
283 (IMX_PAD_SION | 0xf1) /* SEMC_DQS */
284 >;
Simon Glassd3a98cb2023-02-13 08:56:33 -0700285 bootph-pre-ram;
Giulio Benetti6986d6b2020-01-10 15:51:48 +0100286 };
Giulio Benetti6986d6b2020-01-10 15:51:48 +0100287
Marcel Ziswiler118ad852022-11-07 22:22:36 +0100288 pinctrl_lcdif: lcdifgrp {
289 fsl,pins = <
290 MXRT1050_IOMUXC_GPIO_B0_00_LCD_CLK 0x1b0b1
291 MXRT1050_IOMUXC_GPIO_B0_01_LCD_ENABLE 0x1b0b1
292 MXRT1050_IOMUXC_GPIO_B0_02_LCD_HSYNC 0x1b0b1
293 MXRT1050_IOMUXC_GPIO_B0_03_LCD_VSYNC 0x1b0b1
294 MXRT1050_IOMUXC_GPIO_B0_04_LCD_DATA00 0x1b0b1
295 MXRT1050_IOMUXC_GPIO_B0_05_LCD_DATA01 0x1b0b1
296 MXRT1050_IOMUXC_GPIO_B0_06_LCD_DATA02 0x1b0b1
297 MXRT1050_IOMUXC_GPIO_B0_07_LCD_DATA03 0x1b0b1
298 MXRT1050_IOMUXC_GPIO_B0_08_LCD_DATA04 0x1b0b1
299 MXRT1050_IOMUXC_GPIO_B0_09_LCD_DATA05 0x1b0b1
300 MXRT1050_IOMUXC_GPIO_B0_10_LCD_DATA06 0x1b0b1
301 MXRT1050_IOMUXC_GPIO_B0_11_LCD_DATA07 0x1b0b1
302 MXRT1050_IOMUXC_GPIO_B0_12_LCD_DATA08 0x1b0b1
303 MXRT1050_IOMUXC_GPIO_B0_13_LCD_DATA09 0x1b0b1
304 MXRT1050_IOMUXC_GPIO_B0_14_LCD_DATA10 0x1b0b1
305 MXRT1050_IOMUXC_GPIO_B0_15_LCD_DATA11 0x1b0b1
306 MXRT1050_IOMUXC_GPIO_B1_01_LCD_DATA13 0x1b0b1
307 MXRT1050_IOMUXC_GPIO_B1_02_LCD_DATA14 0x1b0b1
308 MXRT1050_IOMUXC_GPIO_B1_03_LCD_DATA15 0x1b0b1
309 MXRT1050_IOMUXC_GPIO_B1_15_GPIO2_IO31 0x0b069
310 MXRT1050_IOMUXC_GPIO_AD_B0_02_GPIO1_IO02 0x0b069
311 >;
312 };
Giulio Benetti6986d6b2020-01-10 15:51:48 +0100313
Marcel Ziswiler118ad852022-11-07 22:22:36 +0100314 pinctrl_lpuart1: lpuart1grp {
Simon Glassd3a98cb2023-02-13 08:56:33 -0700315 bootph-pre-ram;
Marcel Ziswiler118ad852022-11-07 22:22:36 +0100316 };
Giulio Benetti6986d6b2020-01-10 15:51:48 +0100317
Marcel Ziswiler118ad852022-11-07 22:22:36 +0100318 pinctrl_usdhc0: usdhc0grp {
Simon Glassd3a98cb2023-02-13 08:56:33 -0700319 bootph-pre-ram;
Marcel Ziswiler118ad852022-11-07 22:22:36 +0100320 };
321 };
322
323&usdhc1 {
324 compatible = "fsl,imxrt-usdhc";
Simon Glassd3a98cb2023-02-13 08:56:33 -0700325 bootph-pre-ram;
Marcel Ziswiler118ad852022-11-07 22:22:36 +0100326};
327
328&lcdif {
329 pinctrl-names = "default";
330 pinctrl-0 = <&pinctrl_lcdif>;
331 display = <&display0>;
332 status = "okay";
333
334 display0: display0 {
335 bits-per-pixel = <16>;
336 bus-width = <16>;
Giulio Benetti6986d6b2020-01-10 15:51:48 +0100337
Marcel Ziswiler118ad852022-11-07 22:22:36 +0100338 display-timings {
339 timing0: timing0 {
340 clock-frequency = <9300000>;
341 hactive = <480>;
342 vactive = <272>;
343 hback-porch = <4>;
344 hfront-porch = <8>;
345 vback-porch = <4>;
346 vfront-porch = <8>;
347 hsync-len = <41>;
348 vsync-len = <10>;
349 de-active = <1>;
350 pixelclk-active = <0>;
351 hsync-active = <0>;
352 vsync-active = <0>;
353 };
Giulio Benetti6986d6b2020-01-10 15:51:48 +0100354 };
355 };
356};
357
Marcel Ziswiler118ad852022-11-07 22:22:36 +0100358&usbotg1 {
359 dr_mode = "host";
360 status = "okay";
Giulio Benetti6986d6b2020-01-10 15:51:48 +0100361};