xref: /rk3399_ARM-atf/fdts/stm32mp15xx-dhcor-som.dtsi (revision 4c8e8ea772905c1420720a900dd3e7d94eefbc7e)
151e22305SJohann Neuhauser// SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause
251e22305SJohann Neuhauser/*
351e22305SJohann Neuhauser * Copyright (C) Linaro Ltd 2019 - All Rights Reserved
451e22305SJohann Neuhauser * Author: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
551e22305SJohann Neuhauser * Copyright (C) 2020 Marek Vasut <marex@denx.de>
651e22305SJohann Neuhauser * Copyright (C) 2022 DH electronics GmbH
7*4c8e8ea7SYann Gautier * Copyright (C) 2023, STMicroelectronics - All Rights Reserved
851e22305SJohann Neuhauser */
951e22305SJohann Neuhauser
1051e22305SJohann Neuhauser#include "stm32mp15-pinctrl.dtsi"
1151e22305SJohann Neuhauser#include "stm32mp15xxaa-pinctrl.dtsi"
1251e22305SJohann Neuhauser#include <dt-bindings/clock/stm32mp1-clksrc.h>
1351e22305SJohann Neuhauser#include "stm32mp15-ddr3-dhsom-2x4Gb-1066-binG.dtsi"
1451e22305SJohann Neuhauser
1551e22305SJohann Neuhauser/ {
1651e22305SJohann Neuhauser	memory@c0000000 {
1751e22305SJohann Neuhauser		device_type = "memory";
1851e22305SJohann Neuhauser		reg = <0xc0000000 0x40000000>;
1951e22305SJohann Neuhauser	};
2051e22305SJohann Neuhauser};
2151e22305SJohann Neuhauser
2251e22305SJohann Neuhauser&cpu0 {
2351e22305SJohann Neuhauser	cpu-supply = <&vddcore>;
2451e22305SJohann Neuhauser};
2551e22305SJohann Neuhauser
2651e22305SJohann Neuhauser&cpu1 {
2751e22305SJohann Neuhauser	cpu-supply = <&vddcore>;
2851e22305SJohann Neuhauser};
2951e22305SJohann Neuhauser
3051e22305SJohann Neuhauser&hash1 {
3151e22305SJohann Neuhauser	status = "okay";
3251e22305SJohann Neuhauser};
3351e22305SJohann Neuhauser
3451e22305SJohann Neuhauser&i2c4 {
3551e22305SJohann Neuhauser	pinctrl-names = "default";
3651e22305SJohann Neuhauser	pinctrl-0 = <&i2c4_pins_a>;
3751e22305SJohann Neuhauser	i2c-scl-rising-time-ns = <185>;
3851e22305SJohann Neuhauser	i2c-scl-falling-time-ns = <20>;
3951e22305SJohann Neuhauser	status = "okay";
4051e22305SJohann Neuhauser
4151e22305SJohann Neuhauser	pmic: stpmic@33 {
4251e22305SJohann Neuhauser		compatible = "st,stpmic1";
4351e22305SJohann Neuhauser		reg = <0x33>;
4451e22305SJohann Neuhauser		interrupts-extended = <&gpioa 0 IRQ_TYPE_EDGE_FALLING>;
4551e22305SJohann Neuhauser		interrupt-controller;
4651e22305SJohann Neuhauser		#interrupt-cells = <2>;
4751e22305SJohann Neuhauser		status = "okay";
4851e22305SJohann Neuhauser
4951e22305SJohann Neuhauser		regulators {
5051e22305SJohann Neuhauser			compatible = "st,stpmic1-regulators";
5151e22305SJohann Neuhauser			ldo1-supply = <&v3v3>;
5251e22305SJohann Neuhauser			ldo2-supply = <&v3v3>;
5351e22305SJohann Neuhauser			ldo3-supply = <&vdd_ddr>;
5451e22305SJohann Neuhauser			ldo5-supply = <&v3v3>;
5551e22305SJohann Neuhauser			ldo6-supply = <&v3v3>;
5651e22305SJohann Neuhauser			pwr_sw1-supply = <&bst_out>;
5751e22305SJohann Neuhauser			pwr_sw2-supply = <&bst_out>;
5851e22305SJohann Neuhauser
5951e22305SJohann Neuhauser			vddcore: buck1 {
6051e22305SJohann Neuhauser				regulator-name = "vddcore";
6151e22305SJohann Neuhauser				regulator-min-microvolt = <1200000>;
6251e22305SJohann Neuhauser				regulator-max-microvolt = <1350000>;
6351e22305SJohann Neuhauser				regulator-always-on;
6451e22305SJohann Neuhauser				regulator-initial-mode = <0>;
6551e22305SJohann Neuhauser				regulator-over-current-protection;
6651e22305SJohann Neuhauser			};
6751e22305SJohann Neuhauser
6851e22305SJohann Neuhauser			vdd_ddr: buck2 {
6951e22305SJohann Neuhauser				regulator-name = "vdd_ddr";
7051e22305SJohann Neuhauser				regulator-min-microvolt = <1350000>;
7151e22305SJohann Neuhauser				regulator-max-microvolt = <1350000>;
7251e22305SJohann Neuhauser				regulator-always-on;
7351e22305SJohann Neuhauser				regulator-initial-mode = <0>;
7451e22305SJohann Neuhauser				regulator-over-current-protection;
7551e22305SJohann Neuhauser			};
7651e22305SJohann Neuhauser
7751e22305SJohann Neuhauser			vdd: buck3 {
7851e22305SJohann Neuhauser				regulator-name = "vdd";
7951e22305SJohann Neuhauser				regulator-min-microvolt = <3300000>;
8051e22305SJohann Neuhauser				regulator-max-microvolt = <3300000>;
8151e22305SJohann Neuhauser				regulator-always-on;
8251e22305SJohann Neuhauser				regulator-initial-mode = <0>;
8351e22305SJohann Neuhauser				regulator-over-current-protection;
8451e22305SJohann Neuhauser			};
8551e22305SJohann Neuhauser
8651e22305SJohann Neuhauser			v3v3: buck4 {
8751e22305SJohann Neuhauser				regulator-name = "v3v3";
8851e22305SJohann Neuhauser				regulator-min-microvolt = <3300000>;
8951e22305SJohann Neuhauser				regulator-max-microvolt = <3300000>;
9051e22305SJohann Neuhauser				regulator-always-on;
9151e22305SJohann Neuhauser				regulator-over-current-protection;
9251e22305SJohann Neuhauser				regulator-initial-mode = <0>;
9351e22305SJohann Neuhauser			};
9451e22305SJohann Neuhauser
9551e22305SJohann Neuhauser			vdda: ldo1 {
9651e22305SJohann Neuhauser				regulator-name = "vdda";
9751e22305SJohann Neuhauser				regulator-min-microvolt = <2900000>;
9851e22305SJohann Neuhauser				regulator-max-microvolt = <2900000>;
9951e22305SJohann Neuhauser			};
10051e22305SJohann Neuhauser
10151e22305SJohann Neuhauser			v2v8: ldo2 {
10251e22305SJohann Neuhauser				regulator-name = "v2v8";
10351e22305SJohann Neuhauser				regulator-min-microvolt = <2800000>;
10451e22305SJohann Neuhauser				regulator-max-microvolt = <2800000>;
10551e22305SJohann Neuhauser			};
10651e22305SJohann Neuhauser
10751e22305SJohann Neuhauser			vtt_ddr: ldo3 {
10851e22305SJohann Neuhauser				regulator-name = "vtt_ddr";
10951e22305SJohann Neuhauser				regulator-always-on;
11051e22305SJohann Neuhauser				regulator-over-current-protection;
11151e22305SJohann Neuhauser				st,regulator-sink-source;
11251e22305SJohann Neuhauser			};
11351e22305SJohann Neuhauser
11451e22305SJohann Neuhauser			vdd_usb: ldo4 {
11551e22305SJohann Neuhauser				regulator-name = "vdd_usb";
11651e22305SJohann Neuhauser				regulator-min-microvolt = <3300000>;
11751e22305SJohann Neuhauser				regulator-max-microvolt = <3300000>;
11851e22305SJohann Neuhauser			};
11951e22305SJohann Neuhauser
12051e22305SJohann Neuhauser			vdd_sd: ldo5 {
12151e22305SJohann Neuhauser				regulator-name = "vdd_sd";
12251e22305SJohann Neuhauser				regulator-min-microvolt = <2900000>;
12351e22305SJohann Neuhauser				regulator-max-microvolt = <2900000>;
12451e22305SJohann Neuhauser				regulator-boot-on;
12551e22305SJohann Neuhauser			};
12651e22305SJohann Neuhauser
12751e22305SJohann Neuhauser			v1v8: ldo6 {
12851e22305SJohann Neuhauser				regulator-name = "v1v8";
12951e22305SJohann Neuhauser				regulator-min-microvolt = <1800000>;
13051e22305SJohann Neuhauser				regulator-max-microvolt = <1800000>;
13151e22305SJohann Neuhauser				regulator-enable-ramp-delay = <300000>;
13251e22305SJohann Neuhauser			};
13351e22305SJohann Neuhauser
13451e22305SJohann Neuhauser			vref_ddr: vref_ddr {
13551e22305SJohann Neuhauser				regulator-name = "vref_ddr";
13651e22305SJohann Neuhauser				regulator-always-on;
13751e22305SJohann Neuhauser			};
13851e22305SJohann Neuhauser
13951e22305SJohann Neuhauser			bst_out: boost {
14051e22305SJohann Neuhauser				regulator-name = "bst_out";
14151e22305SJohann Neuhauser			};
14251e22305SJohann Neuhauser
14351e22305SJohann Neuhauser			vbus_otg: pwr_sw1 {
14451e22305SJohann Neuhauser				regulator-name = "vbus_otg";
14551e22305SJohann Neuhauser				regulator-active-discharge = <1>;
14651e22305SJohann Neuhauser			};
14751e22305SJohann Neuhauser
14851e22305SJohann Neuhauser			vbus_sw: pwr_sw2 {
14951e22305SJohann Neuhauser				regulator-name = "vbus_sw";
15051e22305SJohann Neuhauser				regulator-active-discharge = <1>;
15151e22305SJohann Neuhauser			};
15251e22305SJohann Neuhauser		};
15351e22305SJohann Neuhauser	};
15451e22305SJohann Neuhauser};
15551e22305SJohann Neuhauser
15651e22305SJohann Neuhauser&iwdg2 {
15751e22305SJohann Neuhauser	timeout-sec = <32>;
15851e22305SJohann Neuhauser	status = "okay";
15951e22305SJohann Neuhauser};
16051e22305SJohann Neuhauser
16151e22305SJohann Neuhauser&pwr_regulators {
16251e22305SJohann Neuhauser	vdd-supply = <&vdd>;
16351e22305SJohann Neuhauser	vdd_3v3_usbfs-supply = <&vdd_usb>;
16451e22305SJohann Neuhauser};
16551e22305SJohann Neuhauser
16651e22305SJohann Neuhauser&qspi {
16751e22305SJohann Neuhauser	pinctrl-names = "default";
168*4c8e8ea7SYann Gautier	pinctrl-0 = <&qspi_clk_pins_a
169*4c8e8ea7SYann Gautier		     &qspi_bk1_pins_a
170*4c8e8ea7SYann Gautier		     &qspi_cs1_pins_a>;
17151e22305SJohann Neuhauser	reg = <0x58003000 0x1000>, <0x70000000 0x200000>;
17251e22305SJohann Neuhauser	#address-cells = <1>;
17351e22305SJohann Neuhauser	#size-cells = <0>;
17451e22305SJohann Neuhauser	status = "okay";
17551e22305SJohann Neuhauser
17651e22305SJohann Neuhauser	flash0: flash@0 {
17751e22305SJohann Neuhauser		compatible = "jedec,spi-nor";
17851e22305SJohann Neuhauser		reg = <0>;
17951e22305SJohann Neuhauser		spi-rx-bus-width = <4>;
18051e22305SJohann Neuhauser		spi-max-frequency = <50000000>;
18151e22305SJohann Neuhauser		#address-cells = <1>;
18251e22305SJohann Neuhauser		#size-cells = <1>;
18351e22305SJohann Neuhauser	};
18451e22305SJohann Neuhauser};
18551e22305SJohann Neuhauser
18651e22305SJohann Neuhauser&rcc {
18751e22305SJohann Neuhauser	st,clksrc = <
18851e22305SJohann Neuhauser		CLK_MPU_PLL1P
18951e22305SJohann Neuhauser		CLK_AXI_PLL2P
19051e22305SJohann Neuhauser		CLK_MCU_PLL3P
19151e22305SJohann Neuhauser		CLK_PLL12_HSE
19251e22305SJohann Neuhauser		CLK_PLL3_HSE
19351e22305SJohann Neuhauser		CLK_PLL4_HSE
19451e22305SJohann Neuhauser		CLK_RTC_LSE
19551e22305SJohann Neuhauser		CLK_MCO1_DISABLED
19651e22305SJohann Neuhauser		CLK_MCO2_DISABLED
19751e22305SJohann Neuhauser	>;
19851e22305SJohann Neuhauser
19951e22305SJohann Neuhauser	st,clkdiv = <
20051e22305SJohann Neuhauser		1 /*MPU*/
20151e22305SJohann Neuhauser		0 /*AXI*/
20251e22305SJohann Neuhauser		0 /*MCU*/
20351e22305SJohann Neuhauser		1 /*APB1*/
20451e22305SJohann Neuhauser		1 /*APB2*/
20551e22305SJohann Neuhauser		1 /*APB3*/
20651e22305SJohann Neuhauser		1 /*APB4*/
20751e22305SJohann Neuhauser		2 /*APB5*/
20851e22305SJohann Neuhauser		23 /*RTC*/
20951e22305SJohann Neuhauser		0 /*MCO1*/
21051e22305SJohann Neuhauser		0 /*MCO2*/
21151e22305SJohann Neuhauser	>;
21251e22305SJohann Neuhauser
21351e22305SJohann Neuhauser	st,pkcs = <
21451e22305SJohann Neuhauser		CLK_CKPER_HSE
21551e22305SJohann Neuhauser		CLK_FMC_ACLK
21651e22305SJohann Neuhauser		CLK_QSPI_ACLK
21751e22305SJohann Neuhauser		CLK_ETH_DISABLED
21851e22305SJohann Neuhauser		CLK_SDMMC12_PLL4P
21951e22305SJohann Neuhauser		CLK_DSI_DSIPLL
22051e22305SJohann Neuhauser		CLK_STGEN_HSE
22151e22305SJohann Neuhauser		CLK_USBPHY_HSE
22251e22305SJohann Neuhauser		CLK_SPI2S1_PLL3Q
22351e22305SJohann Neuhauser		CLK_SPI2S23_PLL3Q
22451e22305SJohann Neuhauser		CLK_SPI45_HSI
22551e22305SJohann Neuhauser		CLK_SPI6_HSI
22651e22305SJohann Neuhauser		CLK_I2C46_HSI
22751e22305SJohann Neuhauser		CLK_SDMMC3_PLL4P
22851e22305SJohann Neuhauser		CLK_USBO_USBPHY
22951e22305SJohann Neuhauser		CLK_ADC_CKPER
23051e22305SJohann Neuhauser		CLK_CEC_LSE
23151e22305SJohann Neuhauser		CLK_I2C12_HSI
23251e22305SJohann Neuhauser		CLK_I2C35_HSI
23351e22305SJohann Neuhauser		CLK_UART1_HSI
23451e22305SJohann Neuhauser		CLK_UART24_HSI
23551e22305SJohann Neuhauser		CLK_UART35_HSI
23651e22305SJohann Neuhauser		CLK_UART6_HSI
23751e22305SJohann Neuhauser		CLK_UART78_HSI
23851e22305SJohann Neuhauser		CLK_SPDIF_PLL4P
23951e22305SJohann Neuhauser		CLK_FDCAN_PLL4R
24051e22305SJohann Neuhauser		CLK_SAI1_PLL3Q
24151e22305SJohann Neuhauser		CLK_SAI2_PLL3Q
24251e22305SJohann Neuhauser		CLK_SAI3_PLL3Q
24351e22305SJohann Neuhauser		CLK_SAI4_PLL3Q
24451e22305SJohann Neuhauser		CLK_RNG1_LSI
24551e22305SJohann Neuhauser		CLK_RNG2_LSI
24651e22305SJohann Neuhauser		CLK_LPTIM1_PCLK1
24751e22305SJohann Neuhauser		CLK_LPTIM23_PCLK3
24851e22305SJohann Neuhauser		CLK_LPTIM45_LSE
24951e22305SJohann Neuhauser	>;
25051e22305SJohann Neuhauser
25151e22305SJohann Neuhauser	/* VCO = 1300.0 MHz => P = 650 (CPU) */
25251e22305SJohann Neuhauser	pll1: st,pll@0 {
25351e22305SJohann Neuhauser		compatible = "st,stm32mp1-pll";
25451e22305SJohann Neuhauser		reg = <0>;
25551e22305SJohann Neuhauser		cfg = <2 80 0 0 0 PQR(1,0,0)>;
25651e22305SJohann Neuhauser		frac = <0x800>;
25751e22305SJohann Neuhauser	};
25851e22305SJohann Neuhauser
25951e22305SJohann Neuhauser	/* VCO = 1066.0 MHz => P = 266 (AXI), Q = 533 (GPU), R = 533 (DDR) */
26051e22305SJohann Neuhauser	pll2: st,pll@1 {
26151e22305SJohann Neuhauser		compatible = "st,stm32mp1-pll";
26251e22305SJohann Neuhauser		reg = <1>;
26351e22305SJohann Neuhauser		cfg = <2 65 1 0 0 PQR(1,1,1)>;
26451e22305SJohann Neuhauser		frac = <0x1400>;
26551e22305SJohann Neuhauser	};
26651e22305SJohann Neuhauser
26751e22305SJohann Neuhauser	/* VCO = 417.8 MHz => P = 209, Q = 24, R = 11 */
26851e22305SJohann Neuhauser	pll3: st,pll@2 {
26951e22305SJohann Neuhauser		compatible = "st,stm32mp1-pll";
27051e22305SJohann Neuhauser		reg = <2>;
27151e22305SJohann Neuhauser		cfg = <1 33 1 16 36 PQR(1,1,1)>;
27251e22305SJohann Neuhauser		frac = <0x1a04>;
27351e22305SJohann Neuhauser	};
27451e22305SJohann Neuhauser
27551e22305SJohann Neuhauser	/* VCO = 600.0 MHz => P = 99, Q = 74, R = 99 */
27651e22305SJohann Neuhauser	pll4: st,pll@3 {
27751e22305SJohann Neuhauser		compatible = "st,stm32mp1-pll";
27851e22305SJohann Neuhauser		reg = <3>;
27951e22305SJohann Neuhauser		cfg = <3 98 5 7 5 PQR(1,1,1)>;
28051e22305SJohann Neuhauser	};
28151e22305SJohann Neuhauser};
28251e22305SJohann Neuhauser
28351e22305SJohann Neuhauser&rng1 {
28451e22305SJohann Neuhauser	status = "okay";
28551e22305SJohann Neuhauser};
28651e22305SJohann Neuhauser
28751e22305SJohann Neuhauser&rtc {
28851e22305SJohann Neuhauser	status = "okay";
28951e22305SJohann Neuhauser};
290