blob: 15a04ae927e7d41fe6c153ca9de447651fce48b2 [file] [log] [blame]
Patrice Chotard00442d02019-02-12 16:50:38 +01001// SPDX-License-Identifier: GPL-2.0+ OR BSD-3-Clause
2/*
3 * Copyright : STMicroelectronics 2018
4 */
5
6#include <dt-bindings/clock/stm32mp1-clksrc.h>
Patrick Delaunay48c5e902020-03-06 17:54:41 +01007#include "stm32mp15-u-boot.dtsi"
Patrice Chotard00442d02019-02-12 16:50:38 +01008#include "stm32mp15-ddr3-1x4Gb-1066-binG.dtsi"
9
10/ {
11 aliases {
12 i2c3 = &i2c4;
Patrick Delaunay58bc0cd2019-03-29 15:42:23 +010013 usb0 = &usbotg_hs;
Patrice Chotard00442d02019-02-12 16:50:38 +010014 };
15 config {
16 u-boot,boot-led = "heartbeat";
17 u-boot,error-led = "error";
Patrick Delaunay9c88dbf2021-07-26 11:21:36 +020018 u-boot,mmc-env-partition = "fip";
Patrice Chotard00442d02019-02-12 16:50:38 +010019 st,adc_usb_pd = <&adc1 18>, <&adc1 19>;
Patrick Delaunay466d3af2021-07-09 09:53:37 +020020 st,fastboot-gpios = <&gpioa 13 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>;
21 st,stm32prog-gpios = <&gpioa 14 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>;
Patrice Chotard00442d02019-02-12 16:50:38 +010022 };
Etienne Carrierec461e1a2020-06-05 09:24:30 +020023
Patrick Delaunay87e83322021-09-14 14:14:52 +020024#if defined(CONFIG_STM32MP15x_STM32IMAGE) || defined(CONFIG_SPL)
Patrick Delaunay9c88dbf2021-07-26 11:21:36 +020025 config {
26 u-boot,mmc-env-partition = "ssbl";
27 };
Patrick Delaunay87e83322021-09-14 14:14:52 +020028#endif
Patrick Delaunay9c88dbf2021-07-26 11:21:36 +020029
Patrick Delaunay87e83322021-09-14 14:14:52 +020030#ifdef CONFIG_STM32MP15x_STM32IMAGE
Patrick Delaunayf8fcabf2021-07-26 11:21:35 +020031 /* only needed for boot with TF-A, witout FIP support */
Etienne Carrierec461e1a2020-06-05 09:24:30 +020032 firmware {
33 optee {
34 compatible = "linaro,optee-tz";
35 method = "smc";
36 };
37 };
38
39 reserved-memory {
Alexandru Gagniuc9bf2f5b2021-07-15 14:19:27 -050040 u-boot,dm-spl;
41
Etienne Carrierec461e1a2020-06-05 09:24:30 +020042 optee@de000000 {
43 reg = <0xde000000 0x02000000>;
44 no-map;
Alexandru Gagniuc9bf2f5b2021-07-15 14:19:27 -050045 u-boot,dm-spl;
Etienne Carrierec461e1a2020-06-05 09:24:30 +020046 };
47 };
Patrick Delaunayf8fcabf2021-07-26 11:21:35 +020048#endif
Etienne Carrierec461e1a2020-06-05 09:24:30 +020049
Patrice Chotard00442d02019-02-12 16:50:38 +010050 led {
51 red {
52 label = "error";
53 gpios = <&gpioa 13 GPIO_ACTIVE_LOW>;
54 default-state = "off";
55 status = "okay";
56 };
Patrice Chotard00442d02019-02-12 16:50:38 +010057 };
58};
59
Patrice Chotarde861c202019-02-12 16:50:41 +010060&adc {
Patrice Chotarde861c202019-02-12 16:50:41 +010061 status = "okay";
Patrice Chotarde861c202019-02-12 16:50:41 +010062};
63
Patrice Chotard00442d02019-02-12 16:50:38 +010064&clk_hse {
65 st,digbypass;
66};
67
68&i2c4 {
69 u-boot,dm-pre-reloc;
70};
71
72&i2c4_pins_a {
73 u-boot,dm-pre-reloc;
74 pins {
75 u-boot,dm-pre-reloc;
76 };
77};
78
79&pmic {
80 u-boot,dm-pre-reloc;
81};
82
83&rcc {
84 st,clksrc = <
85 CLK_MPU_PLL1P
86 CLK_AXI_PLL2P
87 CLK_MCU_PLL3P
88 CLK_PLL12_HSE
89 CLK_PLL3_HSE
90 CLK_PLL4_HSE
91 CLK_RTC_LSE
92 CLK_MCO1_DISABLED
93 CLK_MCO2_DISABLED
94 >;
95
96 st,clkdiv = <
97 1 /*MPU*/
98 0 /*AXI*/
99 0 /*MCU*/
100 1 /*APB1*/
101 1 /*APB2*/
102 1 /*APB3*/
103 1 /*APB4*/
104 2 /*APB5*/
105 23 /*RTC*/
106 0 /*MCO1*/
107 0 /*MCO2*/
108 >;
109
110 st,pkcs = <
111 CLK_CKPER_HSE
112 CLK_FMC_ACLK
113 CLK_QSPI_ACLK
114 CLK_ETH_DISABLED
115 CLK_SDMMC12_PLL4P
116 CLK_DSI_DSIPLL
117 CLK_STGEN_HSE
118 CLK_USBPHY_HSE
119 CLK_SPI2S1_PLL3Q
120 CLK_SPI2S23_PLL3Q
121 CLK_SPI45_HSI
122 CLK_SPI6_HSI
123 CLK_I2C46_HSI
124 CLK_SDMMC3_PLL4P
125 CLK_USBO_USBPHY
126 CLK_ADC_CKPER
127 CLK_CEC_LSE
128 CLK_I2C12_HSI
129 CLK_I2C35_HSI
130 CLK_UART1_HSI
131 CLK_UART24_HSI
132 CLK_UART35_HSI
133 CLK_UART6_HSI
134 CLK_UART78_HSI
135 CLK_SPDIF_PLL4P
Antonio Borneo84159e82020-01-28 10:11:01 +0100136 CLK_FDCAN_PLL4R
Patrice Chotard00442d02019-02-12 16:50:38 +0100137 CLK_SAI1_PLL3Q
138 CLK_SAI2_PLL3Q
139 CLK_SAI3_PLL3Q
140 CLK_SAI4_PLL3Q
141 CLK_RNG1_LSI
142 CLK_RNG2_LSI
143 CLK_LPTIM1_PCLK1
144 CLK_LPTIM23_PCLK3
145 CLK_LPTIM45_LSE
146 >;
147
Patrice Chotard00442d02019-02-12 16:50:38 +0100148 /* VCO = 1066.0 MHz => P = 266 (AXI), Q = 533 (GPU), R = 533 (DDR) */
149 pll2: st,pll@1 {
Patrick Delaunayc22caac2020-01-28 10:11:03 +0100150 compatible = "st,stm32mp1-pll";
151 reg = <1>;
Patrice Chotard00442d02019-02-12 16:50:38 +0100152 cfg = < 2 65 1 0 0 PQR(1,1,1) >;
153 frac = < 0x1400 >;
154 u-boot,dm-pre-reloc;
155 };
156
157 /* VCO = 417.8 MHz => P = 209, Q = 24, R = 11 */
158 pll3: st,pll@2 {
Patrick Delaunayc22caac2020-01-28 10:11:03 +0100159 compatible = "st,stm32mp1-pll";
160 reg = <2>;
Patrice Chotard00442d02019-02-12 16:50:38 +0100161 cfg = < 1 33 1 16 36 PQR(1,1,1) >;
162 frac = < 0x1a04 >;
163 u-boot,dm-pre-reloc;
164 };
165
166 /* VCO = 594.0 MHz => P = 99, Q = 74, R = 74 */
167 pll4: st,pll@3 {
Patrick Delaunayc22caac2020-01-28 10:11:03 +0100168 compatible = "st,stm32mp1-pll";
169 reg = <3>;
Patrice Chotard00442d02019-02-12 16:50:38 +0100170 cfg = < 3 98 5 7 7 PQR(1,1,1) >;
171 u-boot,dm-pre-reloc;
172 };
173};
174
175&sdmmc1 {
176 u-boot,dm-spl;
177};
178
179&sdmmc1_b4_pins_a {
180 u-boot,dm-spl;
Patrick Delaunay48c5e902020-03-06 17:54:41 +0100181 pins1 {
182 u-boot,dm-spl;
183 };
184 pins2 {
Patrice Chotard00442d02019-02-12 16:50:38 +0100185 u-boot,dm-spl;
186 };
187};
188
189&uart4 {
190 u-boot,dm-pre-reloc;
191};
192
193&uart4_pins_a {
194 u-boot,dm-pre-reloc;
195 pins1 {
196 u-boot,dm-pre-reloc;
197 };
198 pins2 {
199 u-boot,dm-pre-reloc;
Patrick Delaunay5179a852019-07-30 19:16:18 +0200200 /* pull-up on rx to avoid floating level */
201 bias-pull-up;
Patrice Chotard00442d02019-02-12 16:50:38 +0100202 };
203};
204
205&usbotg_hs {
Patrick Delaunay7f3384d2019-03-29 15:42:24 +0100206 u-boot,force-b-session-valid;
Patrice Chotard00442d02019-02-12 16:50:38 +0100207};