blob: 0101962ea5e729d58a6eb758c13e49297cd6966f [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 Delaunayf8fcabf2021-07-26 11:21:35 +020024#ifdef CONFIG_STM32MP15x_STM32IMAGE
Patrick Delaunay9c88dbf2021-07-26 11:21:36 +020025 config {
26 u-boot,mmc-env-partition = "ssbl";
27 };
28
Patrick Delaunayf8fcabf2021-07-26 11:21:35 +020029 /* only needed for boot with TF-A, witout FIP support */
Etienne Carrierec461e1a2020-06-05 09:24:30 +020030 firmware {
31 optee {
32 compatible = "linaro,optee-tz";
33 method = "smc";
34 };
35 };
36
37 reserved-memory {
Alexandru Gagniuc9bf2f5b2021-07-15 14:19:27 -050038 u-boot,dm-spl;
39
Etienne Carrierec461e1a2020-06-05 09:24:30 +020040 optee@de000000 {
41 reg = <0xde000000 0x02000000>;
42 no-map;
Alexandru Gagniuc9bf2f5b2021-07-15 14:19:27 -050043 u-boot,dm-spl;
Etienne Carrierec461e1a2020-06-05 09:24:30 +020044 };
45 };
Patrick Delaunayf8fcabf2021-07-26 11:21:35 +020046#endif
Etienne Carrierec461e1a2020-06-05 09:24:30 +020047
Patrice Chotard00442d02019-02-12 16:50:38 +010048 led {
49 red {
50 label = "error";
51 gpios = <&gpioa 13 GPIO_ACTIVE_LOW>;
52 default-state = "off";
53 status = "okay";
54 };
Patrice Chotard00442d02019-02-12 16:50:38 +010055 };
56};
57
Patrice Chotarde861c202019-02-12 16:50:41 +010058&adc {
Patrice Chotarde861c202019-02-12 16:50:41 +010059 status = "okay";
Patrice Chotarde861c202019-02-12 16:50:41 +010060};
61
Patrice Chotard00442d02019-02-12 16:50:38 +010062&clk_hse {
63 st,digbypass;
64};
65
66&i2c4 {
67 u-boot,dm-pre-reloc;
68};
69
70&i2c4_pins_a {
71 u-boot,dm-pre-reloc;
72 pins {
73 u-boot,dm-pre-reloc;
74 };
75};
76
77&pmic {
78 u-boot,dm-pre-reloc;
79};
80
81&rcc {
82 st,clksrc = <
83 CLK_MPU_PLL1P
84 CLK_AXI_PLL2P
85 CLK_MCU_PLL3P
86 CLK_PLL12_HSE
87 CLK_PLL3_HSE
88 CLK_PLL4_HSE
89 CLK_RTC_LSE
90 CLK_MCO1_DISABLED
91 CLK_MCO2_DISABLED
92 >;
93
94 st,clkdiv = <
95 1 /*MPU*/
96 0 /*AXI*/
97 0 /*MCU*/
98 1 /*APB1*/
99 1 /*APB2*/
100 1 /*APB3*/
101 1 /*APB4*/
102 2 /*APB5*/
103 23 /*RTC*/
104 0 /*MCO1*/
105 0 /*MCO2*/
106 >;
107
108 st,pkcs = <
109 CLK_CKPER_HSE
110 CLK_FMC_ACLK
111 CLK_QSPI_ACLK
112 CLK_ETH_DISABLED
113 CLK_SDMMC12_PLL4P
114 CLK_DSI_DSIPLL
115 CLK_STGEN_HSE
116 CLK_USBPHY_HSE
117 CLK_SPI2S1_PLL3Q
118 CLK_SPI2S23_PLL3Q
119 CLK_SPI45_HSI
120 CLK_SPI6_HSI
121 CLK_I2C46_HSI
122 CLK_SDMMC3_PLL4P
123 CLK_USBO_USBPHY
124 CLK_ADC_CKPER
125 CLK_CEC_LSE
126 CLK_I2C12_HSI
127 CLK_I2C35_HSI
128 CLK_UART1_HSI
129 CLK_UART24_HSI
130 CLK_UART35_HSI
131 CLK_UART6_HSI
132 CLK_UART78_HSI
133 CLK_SPDIF_PLL4P
Antonio Borneo84159e82020-01-28 10:11:01 +0100134 CLK_FDCAN_PLL4R
Patrice Chotard00442d02019-02-12 16:50:38 +0100135 CLK_SAI1_PLL3Q
136 CLK_SAI2_PLL3Q
137 CLK_SAI3_PLL3Q
138 CLK_SAI4_PLL3Q
139 CLK_RNG1_LSI
140 CLK_RNG2_LSI
141 CLK_LPTIM1_PCLK1
142 CLK_LPTIM23_PCLK3
143 CLK_LPTIM45_LSE
144 >;
145
Patrice Chotard00442d02019-02-12 16:50:38 +0100146 /* VCO = 1066.0 MHz => P = 266 (AXI), Q = 533 (GPU), R = 533 (DDR) */
147 pll2: st,pll@1 {
Patrick Delaunayc22caac2020-01-28 10:11:03 +0100148 compatible = "st,stm32mp1-pll";
149 reg = <1>;
Patrice Chotard00442d02019-02-12 16:50:38 +0100150 cfg = < 2 65 1 0 0 PQR(1,1,1) >;
151 frac = < 0x1400 >;
152 u-boot,dm-pre-reloc;
153 };
154
155 /* VCO = 417.8 MHz => P = 209, Q = 24, R = 11 */
156 pll3: st,pll@2 {
Patrick Delaunayc22caac2020-01-28 10:11:03 +0100157 compatible = "st,stm32mp1-pll";
158 reg = <2>;
Patrice Chotard00442d02019-02-12 16:50:38 +0100159 cfg = < 1 33 1 16 36 PQR(1,1,1) >;
160 frac = < 0x1a04 >;
161 u-boot,dm-pre-reloc;
162 };
163
164 /* VCO = 594.0 MHz => P = 99, Q = 74, R = 74 */
165 pll4: st,pll@3 {
Patrick Delaunayc22caac2020-01-28 10:11:03 +0100166 compatible = "st,stm32mp1-pll";
167 reg = <3>;
Patrice Chotard00442d02019-02-12 16:50:38 +0100168 cfg = < 3 98 5 7 7 PQR(1,1,1) >;
169 u-boot,dm-pre-reloc;
170 };
171};
172
173&sdmmc1 {
174 u-boot,dm-spl;
175};
176
177&sdmmc1_b4_pins_a {
178 u-boot,dm-spl;
Patrick Delaunay48c5e902020-03-06 17:54:41 +0100179 pins1 {
180 u-boot,dm-spl;
181 };
182 pins2 {
Patrice Chotard00442d02019-02-12 16:50:38 +0100183 u-boot,dm-spl;
184 };
185};
186
187&uart4 {
188 u-boot,dm-pre-reloc;
189};
190
191&uart4_pins_a {
192 u-boot,dm-pre-reloc;
193 pins1 {
194 u-boot,dm-pre-reloc;
195 };
196 pins2 {
197 u-boot,dm-pre-reloc;
Patrick Delaunay5179a852019-07-30 19:16:18 +0200198 /* pull-up on rx to avoid floating level */
199 bias-pull-up;
Patrice Chotard00442d02019-02-12 16:50:38 +0100200 };
201};
202
203&usbotg_hs {
Patrick Delaunay7f3384d2019-03-29 15:42:24 +0100204 u-boot,force-b-session-valid;
Patrice Chotard00442d02019-02-12 16:50:38 +0100205};