Compare commits
102 Commits
v2022.10
...
v2020.10-s
| Author | SHA1 | Date | |
|---|---|---|---|
| 845f1618ea | |||
| b9f621e1d5 | |||
| 201c8ae8d9 | |||
| d2c99cb7e5 | |||
| 96c80bc4ab | |||
| 755a624309 | |||
| 4074f61955 | |||
| e162f7b15a | |||
| f25ae3ad15 | |||
| 3ec26bca18 | |||
| ab6b54a960 | |||
| eac38177a5 | |||
| 24cfdbc039 | |||
| bba889da70 | |||
| 4ad26a89cc | |||
| 88e2f3e3f2 | |||
| e3549a7636 | |||
| 4df4dd68c4 | |||
| 4f13edabfe | |||
| a539394615 | |||
| 1603a3f161 | |||
| 2f37c0df57 | |||
| 5973650434 | |||
| 9af6dce609 | |||
| 01110cd0a9 | |||
| 9bac53ceb9 | |||
| ccf0f7f3a8 | |||
| 71902be420 | |||
| 786b57af24 | |||
| 94fbdb5ad9 | |||
| 883351e230 | |||
| 32619a4db6 | |||
| a9a6ef9f26 | |||
| 530378050a | |||
| 89378cad53 | |||
| a276021ce2 | |||
| a667e88971 | |||
| 9e916f62f9 | |||
| a9a416d7ef | |||
| bdda8b06a9 | |||
| 6b2a718e81 | |||
| eb0109d557 | |||
| 9a54910efc | |||
| 21cc5096c3 | |||
| 427aa1cb63 | |||
| c4628d1760 | |||
| b65b0dab59 | |||
| 2ca27108ba | |||
| 16ea27215d | |||
| fe67dde0a9 | |||
| a27bb329bb | |||
| 155cd5d967 | |||
| 27023f0622 | |||
| dad06fb439 | |||
| ea8d62311f | |||
| 660f93a7dd | |||
| 6b0a2110e3 | |||
| 19200c0da0 | |||
| a4242ee4dd | |||
| 8f4e7f90af | |||
| 8185e4ef32 | |||
| 8394f45f4c | |||
| 1d0aabdada | |||
| 54172bd819 | |||
| 625dc3af9f | |||
| 38cab67688 | |||
| 70ab7eaf11 | |||
| d1531adc7d | |||
| 84af99d7fb | |||
| cbba2eb804 | |||
| 9c66fde95b | |||
| 002c5fe8f4 | |||
| 844f722e5c | |||
| 101b18a11b | |||
| 1c8bb54c75 | |||
| 14a049aac7 | |||
| ad597c3596 | |||
| 35ebbb4dd7 | |||
| c532220188 | |||
| 6f15b18c2a | |||
| 31cb9f8b1e | |||
| 0747c5fd3e | |||
| d019c25475 | |||
| 35607c6fdc | |||
| 06d87a5083 | |||
| 1672d72a2c | |||
| d923687d36 | |||
| 22313e34b2 | |||
| 12d1e62295 | |||
| 18b732f78a | |||
| 938ea5ce35 | |||
| e27bb6886a | |||
| 09a1bd58c7 | |||
| d85f35f67a | |||
| 6f2c14f673 | |||
| 52fd68c0ca | |||
| 54eb65bc01 | |||
| 828055b0f2 | |||
| 7a3599a5a4 | |||
| 7561878cdc | |||
| 9444435a55 | |||
| 5f4cb019c5 |
3
.gitignore
vendored
3
.gitignore
vendored
@ -95,3 +95,6 @@ GTAGS
|
||||
|
||||
# Python cache
|
||||
__pycache__
|
||||
|
||||
/oe-*
|
||||
bitbake-cookerdaemon.log
|
||||
|
||||
30
CONTRIBUTING.md
Normal file
30
CONTRIBUTING.md
Normal file
@ -0,0 +1,30 @@
|
||||
# Contributing guide
|
||||
|
||||
This document serves as a checklist before contributing to this repository. It includes links to read up on if topics are unclear to you.
|
||||
|
||||
This guide mainly focuses on the proper use of Git.
|
||||
|
||||
## 1. Issues
|
||||
|
||||
STM32MPU projects do not activate "Github issues" feature for the time being. If you need to report an issue or question about this project deliverables, you can report them using [ ST Support Center ](https://my.st.com/ols#/ols/newrequest) or [ ST Community MPU Forum ](https://community.st.com/s/topic/0TO0X0000003u2AWAQ/stm32-mpus).
|
||||
|
||||
## 2. Pull Requests
|
||||
|
||||
STMicrolectronics is happy to receive contributions from the community, based on an initial Contributor License Agreement (CLA) procedure.
|
||||
|
||||
* If you are an individual writing original source code and you are sure **you own the intellectual property**, then you need to sign an Individual CLA (https://cla.st.com).
|
||||
* If you work for a company that wants also to allow you to contribute with your work, your company needs to provide a Corporate CLA (https://cla.st.com) mentioning your GitHub account name.
|
||||
* If you are not sure that a CLA (Individual or Corporate) has been signed for your GitHub account you can check here (https://cla.st.com).
|
||||
|
||||
Please note that:
|
||||
* The Corporate CLA will always take precedence over the Individual CLA.
|
||||
* One CLA submission is sufficient, for any project proposed by STMicroelectronics.
|
||||
|
||||
__How to proceed__
|
||||
|
||||
* We recommend to fork the project in your GitHub account to further develop your contribution. Please use the latest commit version.
|
||||
* Please, submit one Pull Request for one new feature or proposal. This will ease the analysis and final merge if accepted.
|
||||
|
||||
__Note__
|
||||
|
||||
Merge will not be done directly in GitHub but it will need first to follow internal integration process before public deliver in a standard release. The Pull request will stay open until it is merged and delivered.
|
||||
2
Makefile
2
Makefile
@ -3,7 +3,7 @@
|
||||
VERSION = 2020
|
||||
PATCHLEVEL = 10
|
||||
SUBLEVEL =
|
||||
EXTRAVERSION =
|
||||
EXTRAVERSION = -stm32mp-r1.1
|
||||
NAME =
|
||||
|
||||
# *DOCUMENTATION*
|
||||
|
||||
@ -8,6 +8,4 @@
|
||||
|
||||
#define CONFIG_SYS_BOOT_RAMDISK_HIGH
|
||||
|
||||
#define CONFIG_LMB
|
||||
|
||||
#endif /*__ASM_ARC_CONFIG_H_ */
|
||||
|
||||
@ -943,13 +943,21 @@ dtb-$(CONFIG_ARCH_ASPEED) += ast2500-evb.dtb
|
||||
dtb-$(CONFIG_ARCH_STI) += stih410-b2260.dtb
|
||||
|
||||
dtb-$(CONFIG_STM32MP15x) += \
|
||||
stm32mp157a-dk1.dtb \
|
||||
stm32mp157a-avenger96.dtb \
|
||||
stm32mp157a-dk1.dtb \
|
||||
stm32mp157a-ed1.dtb \
|
||||
stm32mp157a-ev1.dtb \
|
||||
stm32mp157c-dk2.dtb \
|
||||
stm32mp157c-ed1.dtb \
|
||||
stm32mp157c-ev1.dtb \
|
||||
stm32mp157c-odyssey.dtb \
|
||||
stm32mp15xx-dhcom-drc02.dtb \
|
||||
stm32mp157d-dk1.dtb \
|
||||
stm32mp157d-ed1.dtb \
|
||||
stm32mp157d-ev1.dtb \
|
||||
stm32mp157f-dk2.dtb \
|
||||
stm32mp157f-ed1.dtb \
|
||||
stm32mp157f-ev1.dtb \
|
||||
stm32mp15xx-dhcom-pdk2.dtb \
|
||||
stm32mp15xx-dhcor-avenger96.dtb
|
||||
|
||||
|
||||
@ -14,6 +14,7 @@
|
||||
st,mem-speed = <DDR_MEM_SPEED>;
|
||||
st,mem-size = <DDR_MEM_SIZE>;
|
||||
|
||||
#ifndef CONFIG_TFABOOT
|
||||
st,ctl-reg = <
|
||||
DDR_MSTR
|
||||
DDR_MRCTRL0
|
||||
@ -133,7 +134,7 @@
|
||||
>;
|
||||
|
||||
#endif
|
||||
|
||||
#endif
|
||||
status = "okay";
|
||||
};
|
||||
};
|
||||
|
||||
@ -15,7 +15,7 @@
|
||||
* Save Date: 2020.02.20, save Time: 18:45:20
|
||||
*/
|
||||
#define DDR_MEM_COMPATIBLE ddr3-1066-888-bin-g-1x4gb-533mhz
|
||||
#define DDR_MEM_NAME "DDR3-DDR3L 16bits 533000Khz"
|
||||
#define DDR_MEM_NAME "DDR3-DDR3L 16bits 533000kHz"
|
||||
#define DDR_MEM_SPEED 533000
|
||||
#define DDR_MEM_SIZE 0x20000000
|
||||
|
||||
|
||||
@ -15,7 +15,7 @@
|
||||
* Save Date: 2020.02.20, save Time: 18:49:33
|
||||
*/
|
||||
#define DDR_MEM_COMPATIBLE ddr3-1066-888-bin-g-2x4gb-533mhz
|
||||
#define DDR_MEM_NAME "DDR3-DDR3L 32bits 533000Khz"
|
||||
#define DDR_MEM_NAME "DDR3-DDR3L 32bits 533000kHz"
|
||||
#define DDR_MEM_SPEED 533000
|
||||
#define DDR_MEM_SIZE 0x40000000
|
||||
|
||||
|
||||
524
arch/arm/dts/stm32mp15-m4-srm-pinctrl.dtsi
Normal file
524
arch/arm/dts/stm32mp15-m4-srm-pinctrl.dtsi
Normal file
@ -0,0 +1,524 @@
|
||||
// SPDX-License-Identifier: (GPL-2.0+ OR BSD-3-Clause)
|
||||
/*
|
||||
* Copyright (C) STMicroelectronics 2019 - All Rights Reserved
|
||||
* Author: Fabien Dessenne <fabien.dessenne@st.com> for STMicroelectronics.
|
||||
*/
|
||||
|
||||
&pinctrl {
|
||||
m4_adc1_in6_pins_a: m4-adc1-in6 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('F', 12, RSVD)>;
|
||||
};
|
||||
};
|
||||
|
||||
m4_adc12_ain_pins_a: m4-adc12-ain-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('C', 3, RSVD)>, /* ADC1 in13 */
|
||||
<STM32_PINMUX('F', 12, RSVD)>, /* ADC1 in6 */
|
||||
<STM32_PINMUX('F', 13, RSVD)>, /* ADC2 in2 */
|
||||
<STM32_PINMUX('F', 14, RSVD)>; /* ADC2 in6 */
|
||||
};
|
||||
};
|
||||
|
||||
m4_adc12_usb_pwr_pins_a: m4-adc12-usb-pwr-pins-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('A', 4, RSVD)>, /* ADC12 in18 */
|
||||
<STM32_PINMUX('A', 5, RSVD)>; /* ADC12 in19 */
|
||||
};
|
||||
};
|
||||
|
||||
m4_cec_pins_a: m4-cec-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('A', 15, RSVD)>;
|
||||
};
|
||||
};
|
||||
|
||||
m4_cec_pins_b: m4-cec-1 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('B', 6, RSVD)>;
|
||||
};
|
||||
};
|
||||
|
||||
m4_dac_ch1_pins_a: m4-dac-ch1 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('A', 4, RSVD)>;
|
||||
};
|
||||
};
|
||||
|
||||
m4_dac_ch2_pins_a: m4-dac-ch2 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('A', 5, RSVD)>;
|
||||
};
|
||||
};
|
||||
|
||||
m4_dcmi_pins_a: m4-dcmi-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('H', 8, RSVD)>,/* DCMI_HSYNC */
|
||||
<STM32_PINMUX('B', 7, RSVD)>,/* DCMI_VSYNC */
|
||||
<STM32_PINMUX('A', 6, RSVD)>,/* DCMI_PIXCLK */
|
||||
<STM32_PINMUX('H', 9, RSVD)>,/* DCMI_D0 */
|
||||
<STM32_PINMUX('H', 10, RSVD)>,/* DCMI_D1 */
|
||||
<STM32_PINMUX('H', 11, RSVD)>,/* DCMI_D2 */
|
||||
<STM32_PINMUX('H', 12, RSVD)>,/* DCMI_D3 */
|
||||
<STM32_PINMUX('H', 14, RSVD)>,/* DCMI_D4 */
|
||||
<STM32_PINMUX('I', 4, RSVD)>,/* DCMI_D5 */
|
||||
<STM32_PINMUX('B', 8, RSVD)>,/* DCMI_D6 */
|
||||
<STM32_PINMUX('E', 6, RSVD)>,/* DCMI_D7 */
|
||||
<STM32_PINMUX('I', 1, RSVD)>,/* DCMI_D8 */
|
||||
<STM32_PINMUX('H', 7, RSVD)>,/* DCMI_D9 */
|
||||
<STM32_PINMUX('I', 3, RSVD)>,/* DCMI_D10 */
|
||||
<STM32_PINMUX('H', 15, RSVD)>;/* DCMI_D11 */
|
||||
};
|
||||
};
|
||||
|
||||
m4_dfsdm_clkout_pins_a: m4-dfsdm-clkout-pins-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('B', 13, RSVD)>; /* DFSDM_CKOUT */
|
||||
};
|
||||
};
|
||||
|
||||
m4_dfsdm_data1_pins_a: m4-dfsdm-data1-pins-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('C', 3, RSVD)>; /* DFSDM_DATA1 */
|
||||
};
|
||||
};
|
||||
|
||||
m4_dfsdm_data3_pins_a: m4-dfsdm-data3-pins-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('F', 13, RSVD)>; /* DFSDM_DATA3 */
|
||||
};
|
||||
};
|
||||
|
||||
m4_ethernet0_rgmii_pins_a: m4-rgmii-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('G', 5, RSVD)>, /* ETH_RGMII_CLK125 */
|
||||
<STM32_PINMUX('G', 4, RSVD)>, /* ETH_RGMII_GTX_CLK */
|
||||
<STM32_PINMUX('G', 13, RSVD)>, /* ETH_RGMII_TXD0 */
|
||||
<STM32_PINMUX('G', 14, RSVD)>, /* ETH_RGMII_TXD1 */
|
||||
<STM32_PINMUX('C', 2, RSVD)>, /* ETH_RGMII_TXD2 */
|
||||
<STM32_PINMUX('E', 2, RSVD)>, /* ETH_RGMII_TXD3 */
|
||||
<STM32_PINMUX('B', 11, RSVD)>, /* ETH_RGMII_TX_CTL */
|
||||
<STM32_PINMUX('C', 1, RSVD)>, /* ETH_MDC */
|
||||
<STM32_PINMUX('A', 2, RSVD)>, /* ETH_MDIO */
|
||||
<STM32_PINMUX('C', 4, RSVD)>, /* ETH_RGMII_RXD0 */
|
||||
<STM32_PINMUX('C', 5, RSVD)>, /* ETH_RGMII_RXD1 */
|
||||
<STM32_PINMUX('B', 0, RSVD)>, /* ETH_RGMII_RXD2 */
|
||||
<STM32_PINMUX('B', 1, RSVD)>, /* ETH_RGMII_RXD3 */
|
||||
<STM32_PINMUX('A', 1, RSVD)>, /* ETH_RGMII_RX_CLK */
|
||||
<STM32_PINMUX('A', 7, RSVD)>; /* ETH_RGMII_RX_CTL */
|
||||
};
|
||||
};
|
||||
|
||||
m4_fmc_pins_a: m4-fmc-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('D', 4, RSVD)>, /* FMC_NOE */
|
||||
<STM32_PINMUX('D', 5, RSVD)>, /* FMC_NWE */
|
||||
<STM32_PINMUX('D', 11, RSVD)>, /* FMC_A16_FMC_CLE */
|
||||
<STM32_PINMUX('D', 12, RSVD)>, /* FMC_A17_FMC_ALE */
|
||||
<STM32_PINMUX('D', 14, RSVD)>, /* FMC_D0 */
|
||||
<STM32_PINMUX('D', 15, RSVD)>, /* FMC_D1 */
|
||||
<STM32_PINMUX('D', 0, RSVD)>, /* FMC_D2 */
|
||||
<STM32_PINMUX('D', 1, RSVD)>, /* FMC_D3 */
|
||||
<STM32_PINMUX('E', 7, RSVD)>, /* FMC_D4 */
|
||||
<STM32_PINMUX('E', 8, RSVD)>, /* FMC_D5 */
|
||||
<STM32_PINMUX('E', 9, RSVD)>, /* FMC_D6 */
|
||||
<STM32_PINMUX('E', 10, RSVD)>, /* FMC_D7 */
|
||||
<STM32_PINMUX('G', 9, RSVD)>, /* FMC_NE2_FMC_NCE */
|
||||
<STM32_PINMUX('D', 6, RSVD)>; /* FMC_NWAIT */
|
||||
};
|
||||
};
|
||||
|
||||
m4_hdp0_pins_a: m4-hdp0-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('I', 12, RSVD)>; /* HDP0 */
|
||||
};
|
||||
};
|
||||
|
||||
m4_hdp6_pins_a: m4-hdp6-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('K', 5, RSVD)>; /* HDP6 */
|
||||
};
|
||||
};
|
||||
|
||||
m4_hdp7_pins_a: m4-hdp7-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('K', 6, RSVD)>; /* HDP7 */
|
||||
};
|
||||
};
|
||||
|
||||
m4_i2c1_pins_a: m4-i2c1-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('D', 12, RSVD)>, /* I2C1_SCL */
|
||||
<STM32_PINMUX('F', 15, RSVD)>; /* I2C1_SDA */
|
||||
};
|
||||
};
|
||||
|
||||
m4_i2c2_pins_a: m4-i2c2-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('H', 4, RSVD)>, /* I2C2_SCL */
|
||||
<STM32_PINMUX('H', 5, RSVD)>; /* I2C2_SDA */
|
||||
};
|
||||
};
|
||||
|
||||
m4_i2c5_pins_a: m4-i2c5-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('A', 11, RSVD)>, /* I2C5_SCL */
|
||||
<STM32_PINMUX('A', 12, RSVD)>; /* I2C5_SDA */
|
||||
};
|
||||
};
|
||||
|
||||
m4_i2s2_pins_a: m4-i2s2-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('I', 3, RSVD)>, /* I2S2_SDO */
|
||||
<STM32_PINMUX('B', 9, RSVD)>, /* I2S2_WS */
|
||||
<STM32_PINMUX('A', 9, RSVD)>; /* I2S2_CK */
|
||||
};
|
||||
};
|
||||
|
||||
m4_ltdc_pins_a: m4-ltdc-a-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('G', 7, RSVD)>, /* LCD_CLK */
|
||||
<STM32_PINMUX('I', 10, RSVD)>, /* LCD_HSYNC */
|
||||
<STM32_PINMUX('I', 9, RSVD)>, /* LCD_VSYNC */
|
||||
<STM32_PINMUX('F', 10, RSVD)>, /* LCD_DE */
|
||||
<STM32_PINMUX('H', 2, RSVD)>, /* LCD_R0 */
|
||||
<STM32_PINMUX('H', 3, RSVD)>, /* LCD_R1 */
|
||||
<STM32_PINMUX('H', 8, RSVD)>, /* LCD_R2 */
|
||||
<STM32_PINMUX('H', 9, RSVD)>, /* LCD_R3 */
|
||||
<STM32_PINMUX('H', 10, RSVD)>, /* LCD_R4 */
|
||||
<STM32_PINMUX('C', 0, RSVD)>, /* LCD_R5 */
|
||||
<STM32_PINMUX('H', 12, RSVD)>, /* LCD_R6 */
|
||||
<STM32_PINMUX('E', 15, RSVD)>, /* LCD_R7 */
|
||||
<STM32_PINMUX('E', 5, RSVD)>, /* LCD_G0 */
|
||||
<STM32_PINMUX('E', 6, RSVD)>, /* LCD_G1 */
|
||||
<STM32_PINMUX('H', 13, RSVD)>, /* LCD_G2 */
|
||||
<STM32_PINMUX('H', 14, RSVD)>, /* LCD_G3 */
|
||||
<STM32_PINMUX('H', 15, RSVD)>, /* LCD_G4 */
|
||||
<STM32_PINMUX('I', 0, RSVD)>, /* LCD_G5 */
|
||||
<STM32_PINMUX('I', 1, RSVD)>, /* LCD_G6 */
|
||||
<STM32_PINMUX('I', 2, RSVD)>, /* LCD_G7 */
|
||||
<STM32_PINMUX('D', 9, RSVD)>, /* LCD_B0 */
|
||||
<STM32_PINMUX('G', 12, RSVD)>, /* LCD_B1 */
|
||||
<STM32_PINMUX('G', 10, RSVD)>, /* LCD_B2 */
|
||||
<STM32_PINMUX('D', 10, RSVD)>, /* LCD_B3 */
|
||||
<STM32_PINMUX('I', 4, RSVD)>, /* LCD_B4 */
|
||||
<STM32_PINMUX('A', 3, RSVD)>, /* LCD_B5 */
|
||||
<STM32_PINMUX('B', 8, RSVD)>, /* LCD_B6 */
|
||||
<STM32_PINMUX('D', 8, RSVD)>; /* LCD_B7 */
|
||||
};
|
||||
};
|
||||
|
||||
m4_ltdc_pins_b: m4-ltdc-b-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('I', 14, RSVD)>, /* LCD_CLK */
|
||||
<STM32_PINMUX('I', 12, RSVD)>, /* LCD_HSYNC */
|
||||
<STM32_PINMUX('I', 13, RSVD)>, /* LCD_VSYNC */
|
||||
<STM32_PINMUX('K', 7, RSVD)>, /* LCD_DE */
|
||||
<STM32_PINMUX('I', 15, RSVD)>, /* LCD_R0 */
|
||||
<STM32_PINMUX('J', 0, RSVD)>, /* LCD_R1 */
|
||||
<STM32_PINMUX('J', 1, RSVD)>, /* LCD_R2 */
|
||||
<STM32_PINMUX('J', 2, RSVD)>, /* LCD_R3 */
|
||||
<STM32_PINMUX('J', 3, RSVD)>, /* LCD_R4 */
|
||||
<STM32_PINMUX('J', 4, RSVD)>, /* LCD_R5 */
|
||||
<STM32_PINMUX('J', 5, RSVD)>, /* LCD_R6 */
|
||||
<STM32_PINMUX('J', 6, RSVD)>, /* LCD_R7 */
|
||||
<STM32_PINMUX('J', 7, RSVD)>, /* LCD_G0 */
|
||||
<STM32_PINMUX('J', 8, RSVD)>, /* LCD_G1 */
|
||||
<STM32_PINMUX('J', 9, RSVD)>, /* LCD_G2 */
|
||||
<STM32_PINMUX('J', 10, RSVD)>, /* LCD_G3 */
|
||||
<STM32_PINMUX('J', 11, RSVD)>, /* LCD_G4 */
|
||||
<STM32_PINMUX('K', 0, RSVD)>, /* LCD_G5 */
|
||||
<STM32_PINMUX('K', 1, RSVD)>, /* LCD_G6 */
|
||||
<STM32_PINMUX('K', 2, RSVD)>, /* LCD_G7 */
|
||||
<STM32_PINMUX('J', 12, RSVD)>, /* LCD_B0 */
|
||||
<STM32_PINMUX('J', 13, RSVD)>, /* LCD_B1 */
|
||||
<STM32_PINMUX('J', 14, RSVD)>, /* LCD_B2 */
|
||||
<STM32_PINMUX('J', 15, RSVD)>, /* LCD_B3 */
|
||||
<STM32_PINMUX('K', 3, RSVD)>, /* LCD_B4 */
|
||||
<STM32_PINMUX('K', 4, RSVD)>, /* LCD_B5 */
|
||||
<STM32_PINMUX('K', 5, RSVD)>, /* LCD_B6 */
|
||||
<STM32_PINMUX('K', 6, RSVD)>; /* LCD_B7 */
|
||||
};
|
||||
};
|
||||
|
||||
m4_m_can1_pins_a: m4-m-can1-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('H', 13, RSVD)>, /* CAN1_TX */
|
||||
<STM32_PINMUX('I', 9, RSVD)>; /* CAN1_RX */
|
||||
};
|
||||
};
|
||||
|
||||
m4_pwm1_pins_a: m4-pwm1-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('E', 9, RSVD)>, /* TIM1_CH1 */
|
||||
<STM32_PINMUX('E', 11, RSVD)>, /* TIM1_CH2 */
|
||||
<STM32_PINMUX('E', 14, RSVD)>; /* TIM1_CH4 */
|
||||
};
|
||||
};
|
||||
|
||||
m4_pwm2_pins_a: m4-pwm2-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('A', 3, RSVD)>; /* TIM2_CH4 */
|
||||
};
|
||||
};
|
||||
|
||||
m4_pwm3_pins_a: m4-pwm3-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('C', 7, RSVD)>; /* TIM3_CH2 */
|
||||
};
|
||||
};
|
||||
|
||||
m4_pwm4_pins_a: m4-pwm4-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('D', 14, RSVD)>, /* TIM4_CH3 */
|
||||
<STM32_PINMUX('D', 15, RSVD)>; /* TIM4_CH4 */
|
||||
};
|
||||
};
|
||||
|
||||
m4_pwm4_pins_b: m4-pwm4-1 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('D', 13, RSVD)>; /* TIM4_CH2 */
|
||||
};
|
||||
};
|
||||
|
||||
m4_pwm5_pins_a: m4-pwm5-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('H', 11, RSVD)>; /* TIM5_CH2 */
|
||||
};
|
||||
};
|
||||
|
||||
m4_pwm8_pins_a: m4-pwm8-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('I', 2, RSVD)>; /* TIM8_CH4 */
|
||||
};
|
||||
};
|
||||
|
||||
m4_pwm12_pins_a: m4-pwm12-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('H', 6, RSVD)>; /* TIM12_CH1 */
|
||||
};
|
||||
};
|
||||
|
||||
m4_qspi_bk1_pins_a: m4-qspi-bk1-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('F', 8, RSVD)>, /* QSPI_BK1_IO0 */
|
||||
<STM32_PINMUX('F', 9, RSVD)>, /* QSPI_BK1_IO1 */
|
||||
<STM32_PINMUX('F', 7, RSVD)>, /* QSPI_BK1_IO2 */
|
||||
<STM32_PINMUX('F', 6, RSVD)>, /* QSPI_BK1_IO3 */
|
||||
<STM32_PINMUX('B', 6, RSVD)>; /* QSPI_BK1_NCS */
|
||||
};
|
||||
};
|
||||
|
||||
m4_qspi_bk2_pins_a: m4-qspi-bk2-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('H', 2, RSVD)>, /* QSPI_BK2_IO0 */
|
||||
<STM32_PINMUX('H', 3, RSVD)>, /* QSPI_BK2_IO1 */
|
||||
<STM32_PINMUX('G', 10, RSVD)>, /* QSPI_BK2_IO2 */
|
||||
<STM32_PINMUX('G', 7, RSVD)>, /* QSPI_BK2_IO3 */
|
||||
<STM32_PINMUX('C', 0, RSVD)>; /* QSPI_BK2_NCS */
|
||||
};
|
||||
};
|
||||
|
||||
m4_qspi_clk_pins_a: m4-qspi-clk-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('F', 10, RSVD)>; /* QSPI_CLK */
|
||||
};
|
||||
};
|
||||
|
||||
m4_rtc_out2_rmp_pins_a: m4-rtc-out2-rmp-pins-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('I', 8, RSVD)>; /* RTC_OUT2_RMP */
|
||||
};
|
||||
};
|
||||
|
||||
m4_sai2a_pins_a: m4-sai2a-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('I', 5, RSVD)>, /* SAI2_SCK_A */
|
||||
<STM32_PINMUX('I', 6, RSVD)>, /* SAI2_SD_A */
|
||||
<STM32_PINMUX('I', 7, RSVD)>, /* SAI2_FS_A */
|
||||
<STM32_PINMUX('E', 0, RSVD)>; /* SAI2_MCLK_A */
|
||||
};
|
||||
};
|
||||
|
||||
m4_sai2b_pins_a: m4-sai2b-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('E', 12, RSVD)>, /* SAI2_SCK_B */
|
||||
<STM32_PINMUX('E', 13, RSVD)>, /* SAI2_FS_B */
|
||||
<STM32_PINMUX('E', 14, RSVD)>, /* SAI2_MCLK_B */
|
||||
<STM32_PINMUX('F', 11, RSVD)>; /* SAI2_SD_B */
|
||||
};
|
||||
};
|
||||
|
||||
m4_sai2b_pins_b: m4-sai2b-2 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('F', 11, RSVD)>; /* SAI2_SD_B */
|
||||
};
|
||||
};
|
||||
|
||||
m4_sai4a_pins_a: m4-sai4a-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('B', 5, RSVD)>; /* SAI4_SD_A */
|
||||
};
|
||||
};
|
||||
|
||||
m4_sdmmc1_b4_pins_a: m4-sdmmc1-b4-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('C', 8, RSVD)>, /* SDMMC1_D0 */
|
||||
<STM32_PINMUX('C', 9, RSVD)>, /* SDMMC1_D1 */
|
||||
<STM32_PINMUX('C', 10, RSVD)>, /* SDMMC1_D2 */
|
||||
<STM32_PINMUX('C', 11, RSVD)>, /* SDMMC1_D3 */
|
||||
<STM32_PINMUX('D', 2, RSVD)>, /* SDMMC1_CMD */
|
||||
<STM32_PINMUX('C', 12, RSVD)>; /* SDMMC1_CK */
|
||||
};
|
||||
};
|
||||
|
||||
m4_sdmmc1_dir_pins_a: m4-sdmmc1-dir-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('F', 2, RSVD)>, /* SDMMC1_D0DIR */
|
||||
<STM32_PINMUX('C', 7, RSVD)>, /* SDMMC1_D123DIR */
|
||||
<STM32_PINMUX('B', 9, RSVD)>, /* SDMMC1_CDIR */
|
||||
<STM32_PINMUX('E', 4, RSVD)>; /* SDMMC1_CKIN */
|
||||
};
|
||||
};
|
||||
|
||||
m4_sdmmc2_b4_pins_a: m4-sdmmc2-b4-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('B', 14, RSVD)>, /* SDMMC2_D0 */
|
||||
<STM32_PINMUX('B', 15, RSVD)>, /* SDMMC2_D1 */
|
||||
<STM32_PINMUX('B', 3, RSVD)>, /* SDMMC2_D2 */
|
||||
<STM32_PINMUX('B', 4, RSVD)>, /* SDMMC2_D3 */
|
||||
<STM32_PINMUX('G', 6, RSVD)>, /* SDMMC2_CMD */
|
||||
<STM32_PINMUX('E', 3, RSVD)>; /* SDMMC2_CK */
|
||||
};
|
||||
};
|
||||
|
||||
m4_sdmmc2_b4_pins_b: m4-sdmmc2-b4-1 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('B', 14, RSVD)>, /* SDMMC2_D0 */
|
||||
<STM32_PINMUX('B', 15, RSVD)>, /* SDMMC2_D1 */
|
||||
<STM32_PINMUX('B', 3, RSVD)>, /* SDMMC2_D2 */
|
||||
<STM32_PINMUX('B', 4, RSVD)>, /* SDMMC2_D3 */
|
||||
<STM32_PINMUX('G', 6, RSVD)>, /* SDMMC2_CMD */
|
||||
<STM32_PINMUX('E', 3, RSVD)>; /* SDMMC2_CK */
|
||||
};
|
||||
};
|
||||
|
||||
m4_sdmmc2_d47_pins_a: m4-sdmmc2-d47-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('A', 8, RSVD)>, /* SDMMC2_D4 */
|
||||
<STM32_PINMUX('A', 9, RSVD)>, /* SDMMC2_D5 */
|
||||
<STM32_PINMUX('E', 5, RSVD)>, /* SDMMC2_D6 */
|
||||
<STM32_PINMUX('D', 3, RSVD)>; /* SDMMC2_D7 */
|
||||
};
|
||||
};
|
||||
|
||||
m4_sdmmc3_b4_pins_a: m4-sdmmc3-b4-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('F', 0, RSVD)>, /* SDMMC3_D0 */
|
||||
<STM32_PINMUX('F', 4, RSVD)>, /* SDMMC3_D1 */
|
||||
<STM32_PINMUX('F', 5, RSVD)>, /* SDMMC3_D2 */
|
||||
<STM32_PINMUX('D', 7, RSVD)>, /* SDMMC3_D3 */
|
||||
<STM32_PINMUX('F', 1, RSVD)>, /* SDMMC3_CMD */
|
||||
<STM32_PINMUX('G', 15, RSVD)>; /* SDMMC3_CK */
|
||||
};
|
||||
};
|
||||
|
||||
m4_spdifrx_pins_a: m4-spdifrx-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('G', 12, RSVD)>; /* SPDIF_IN1 */
|
||||
};
|
||||
};
|
||||
|
||||
m4_spi4_pins_a: m4-spi4-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('E', 12, RSVD)>, /* SPI4_SCK */
|
||||
<STM32_PINMUX('E', 14, RSVD)>, /* SPI4_MOSI */
|
||||
<STM32_PINMUX('E', 13, RSVD)>; /* SPI4_MISO */
|
||||
};
|
||||
};
|
||||
|
||||
m4_spi5_pins_a: m4-spi5-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('F', 7, RSVD)>, /* SPI5_SCK */
|
||||
<STM32_PINMUX('F', 9, RSVD)>, /* SPI5_MOSI */
|
||||
<STM32_PINMUX('F', 8, RSVD)>; /* SPI5_MISO */
|
||||
};
|
||||
};
|
||||
|
||||
m4_stusb1600_pins_a: m4-stusb1600-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('I', 11, RSVD)>;
|
||||
};
|
||||
};
|
||||
|
||||
m4_uart4_pins_a: m4-uart4-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('G', 11, RSVD)>, /* UART4_TX */
|
||||
<STM32_PINMUX('B', 2, RSVD)>; /* UART4_RX */
|
||||
};
|
||||
};
|
||||
|
||||
m4_uart7_pins_a: m4-uart7-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('E', 8, RSVD)>, /* USART7_TX */
|
||||
<STM32_PINMUX('E', 7, RSVD)>; /* USART7_RX */
|
||||
};
|
||||
};
|
||||
|
||||
m4_usart2_pins_a: m4-usart2-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('D', 5, RSVD)>, /* USART2_TX */
|
||||
<STM32_PINMUX('D', 4, RSVD)>, /* USART2_RTS */
|
||||
<STM32_PINMUX('D', 6, RSVD)>, /* USART2_RX */
|
||||
<STM32_PINMUX('D', 3, RSVD)>; /* USART2_CTS_NSS */
|
||||
};
|
||||
};
|
||||
|
||||
m4_usart3_pins_a: m4-usart3-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('B', 10, RSVD)>, /* USART3_TX */
|
||||
<STM32_PINMUX('G', 8, RSVD)>, /* USART3_RTS */
|
||||
<STM32_PINMUX('B', 12, RSVD)>, /* USART3_RX */
|
||||
<STM32_PINMUX('I', 10, RSVD)>; /* USART3_CTS_NSS */
|
||||
};
|
||||
};
|
||||
|
||||
m4_usart3_pins_b: m4-usart3-1 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('B', 10, RSVD)>, /* USART3_TX */
|
||||
<STM32_PINMUX('G', 8, RSVD)>, /* USART3_RTS */
|
||||
<STM32_PINMUX('B', 12, RSVD)>, /* USART3_RX */
|
||||
<STM32_PINMUX('B', 13, RSVD)>; /* USART3_CTS_NSS */
|
||||
};
|
||||
};
|
||||
|
||||
m4_usbotg_hs_pins_a: m4-usbotg_hs-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('A', 10, RSVD)>; /* OTG_ID */
|
||||
};
|
||||
};
|
||||
|
||||
m4_usbotg_fs_dp_dm_pins_a: m4-usbotg-fs-dp-dm-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('A', 11, RSVD)>, /* OTG_FS_DM */
|
||||
<STM32_PINMUX('A', 12, RSVD)>; /* OTG_FS_DP */
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&pinctrl_z {
|
||||
m4_i2c4_pins_a: m4-i2c4-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('Z', 4, RSVD)>, /* I2C4_SCL */
|
||||
<STM32_PINMUX('Z', 5, RSVD)>; /* I2C4_SDA */
|
||||
};
|
||||
};
|
||||
|
||||
m4_spi1_pins_a: m4-spi1-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('Z', 0, RSVD)>, /* SPI1_SCK */
|
||||
<STM32_PINMUX('Z', 2, RSVD)>, /* SPI1_MOSI */
|
||||
<STM32_PINMUX('Z', 1, RSVD)>; /* SPI1_MISO */
|
||||
};
|
||||
};
|
||||
};
|
||||
442
arch/arm/dts/stm32mp15-m4-srm.dtsi
Normal file
442
arch/arm/dts/stm32mp15-m4-srm.dtsi
Normal file
@ -0,0 +1,442 @@
|
||||
// SPDX-License-Identifier: (GPL-2.0+ OR BSD-3-Clause)
|
||||
/*
|
||||
* Copyright (C) STMicroelectronics 2019 - All Rights Reserved
|
||||
* Author: Fabien Dessenne <fabien.dessenne@st.com> for STMicroelectronics.
|
||||
*/
|
||||
|
||||
&m4_rproc {
|
||||
m4_system_resources {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
m4_timers2: timer@40000000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x40000000 0x400>;
|
||||
clocks = <&rcc TIM2_K>;
|
||||
clock-names = "int";
|
||||
status = "disabled";
|
||||
};
|
||||
m4_timers3: timer@40001000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x40001000 0x400>;
|
||||
clocks = <&rcc TIM3_K>;
|
||||
clock-names = "int";
|
||||
status = "disabled";
|
||||
};
|
||||
m4_timers4: timer@40002000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x40002000 0x400>;
|
||||
clocks = <&rcc TIM4_K>;
|
||||
clock-names = "int";
|
||||
status = "disabled";
|
||||
};
|
||||
m4_timers5: timer@40003000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x40003000 0x400>;
|
||||
clocks = <&rcc TIM5_K>;
|
||||
clock-names = "int";
|
||||
status = "disabled";
|
||||
};
|
||||
m4_timers6: timer@40004000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x40004000 0x400>;
|
||||
clocks = <&rcc TIM6_K>;
|
||||
clock-names = "int";
|
||||
status = "disabled";
|
||||
};
|
||||
m4_timers7: timer@40005000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x40005000 0x400>;
|
||||
clocks = <&rcc TIM7_K>;
|
||||
clock-names = "int";
|
||||
status = "disabled";
|
||||
};
|
||||
m4_timers12: timer@40006000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x40006000 0x400>;
|
||||
clocks = <&rcc TIM12_K>;
|
||||
clock-names = "int";
|
||||
status = "disabled";
|
||||
};
|
||||
m4_timers13: timer@40007000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x40007000 0x400>;
|
||||
clocks = <&rcc TIM13_K>;
|
||||
clock-names = "int";
|
||||
status = "disabled";
|
||||
};
|
||||
m4_timers14: timer@40008000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x40008000 0x400>;
|
||||
clocks = <&rcc TIM14_K>;
|
||||
clock-names = "int";
|
||||
status = "disabled";
|
||||
};
|
||||
m4_lptimer1: timer@40009000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x40009000 0x400>;
|
||||
clocks = <&rcc LPTIM1_K>;
|
||||
clock-names = "mux";
|
||||
status = "disabled";
|
||||
};
|
||||
m4_spi2: spi@4000b000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x4000b000 0x400>;
|
||||
clocks = <&rcc SPI2_K>;
|
||||
status = "disabled";
|
||||
};
|
||||
m4_i2s2: audio-controller@4000b000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x4000b000 0x400>;
|
||||
status = "disabled";
|
||||
};
|
||||
m4_spi3: spi@4000c000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x4000c000 0x400>;
|
||||
clocks = <&rcc SPI3_K>;
|
||||
status = "disabled";
|
||||
};
|
||||
m4_i2s3: audio-controller@4000c000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x4000c000 0x400>;
|
||||
status = "disabled";
|
||||
};
|
||||
m4_spdifrx: audio-controller@4000d000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x4000d000 0x400>;
|
||||
clocks = <&rcc SPDIF_K>;
|
||||
clock-names = "kclk";
|
||||
status = "disabled";
|
||||
};
|
||||
m4_usart2: serial@4000e000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x4000e000 0x400>;
|
||||
interrupt-parent = <&exti>;
|
||||
interrupts = <27 1>;
|
||||
clocks = <&rcc USART2_K>;
|
||||
status = "disabled";
|
||||
};
|
||||
m4_usart3: serial@4000f000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x4000f000 0x400>;
|
||||
interrupt-parent = <&exti>;
|
||||
interrupts = <28 1>;
|
||||
clocks = <&rcc USART3_K>;
|
||||
status = "disabled";
|
||||
};
|
||||
m4_uart4: serial@40010000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x40010000 0x400>;
|
||||
interrupt-parent = <&exti>;
|
||||
interrupts = <30 1>;
|
||||
clocks = <&rcc UART4_K>;
|
||||
status = "disabled";
|
||||
};
|
||||
m4_uart5: serial@40011000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x40011000 0x400>;
|
||||
interrupt-parent = <&exti>;
|
||||
interrupts = <31 1>;
|
||||
clocks = <&rcc UART5_K>;
|
||||
status = "disabled";
|
||||
};
|
||||
m4_i2c1: i2c@40012000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x40012000 0x400>;
|
||||
interrupt-parent = <&exti>;
|
||||
interrupts = <21 1>;
|
||||
clocks = <&rcc I2C1_K>;
|
||||
status = "disabled";
|
||||
};
|
||||
m4_i2c2: i2c@40013000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x40013000 0x400>;
|
||||
interrupt-parent = <&exti>;
|
||||
interrupts = <22 1>;
|
||||
clocks = <&rcc I2C2_K>;
|
||||
status = "disabled";
|
||||
};
|
||||
m4_i2c3: i2c@40014000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x40014000 0x400>;
|
||||
interrupt-parent = <&exti>;
|
||||
interrupts = <23 1>;
|
||||
clocks = <&rcc I2C3_K>;
|
||||
status = "disabled";
|
||||
};
|
||||
m4_i2c5: i2c@40015000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x40015000 0x400>;
|
||||
interrupt-parent = <&exti>;
|
||||
interrupts = <25 1>;
|
||||
clocks = <&rcc I2C5_K>;
|
||||
status = "disabled";
|
||||
};
|
||||
m4_cec: cec@40016000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x40016000 0x400>;
|
||||
interrupt-parent = <&exti>;
|
||||
interrupts = <69 1>;
|
||||
clocks = <&rcc CEC_K>, <&scmi0_clk CK_SCMI0_LSE>;
|
||||
clock-names = "cec", "hdmi-cec";
|
||||
status = "disabled";
|
||||
};
|
||||
m4_dac: dac@40017000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x40017000 0x400>;
|
||||
clocks = <&rcc DAC12>;
|
||||
clock-names = "pclk";
|
||||
status = "disabled";
|
||||
};
|
||||
m4_uart7: serial@40018000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x40018000 0x400>;
|
||||
interrupt-parent = <&exti>;
|
||||
interrupts = <32 1>;
|
||||
clocks = <&rcc UART7_K>;
|
||||
status = "disabled";
|
||||
};
|
||||
m4_uart8: serial@40019000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x40019000 0x400>;
|
||||
interrupt-parent = <&exti>;
|
||||
interrupts = <33 1>;
|
||||
clocks = <&rcc UART8_K>;
|
||||
status = "disabled";
|
||||
};
|
||||
m4_timers1: timer@44000000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x44000000 0x400>;
|
||||
clocks = <&rcc TIM1_K>;
|
||||
clock-names = "int";
|
||||
status = "disabled";
|
||||
};
|
||||
m4_timers8: timer@44001000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x44001000 0x400>;
|
||||
clocks = <&rcc TIM8_K>;
|
||||
clock-names = "int";
|
||||
status = "disabled";
|
||||
};
|
||||
m4_usart6: serial@44003000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x44003000 0x400>;
|
||||
interrupt-parent = <&exti>;
|
||||
interrupts = <29 1>;
|
||||
clocks = <&rcc USART6_K>;
|
||||
status = "disabled";
|
||||
};
|
||||
m4_spi1: spi@44004000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x44004000 0x400>;
|
||||
clocks = <&rcc SPI1_K>;
|
||||
status = "disabled";
|
||||
};
|
||||
m4_i2s1: audio-controller@44004000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x44004000 0x400>;
|
||||
status = "disabled";
|
||||
};
|
||||
m4_spi4: spi@44005000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x44005000 0x400>;
|
||||
clocks = <&rcc SPI4_K>;
|
||||
status = "disabled";
|
||||
};
|
||||
m4_timers15: timer@44006000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x44006000 0x400>;
|
||||
clocks = <&rcc TIM15_K>;
|
||||
clock-names = "int";
|
||||
status = "disabled";
|
||||
};
|
||||
m4_timers16: timer@44007000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x44007000 0x400>;
|
||||
clocks = <&rcc TIM16_K>;
|
||||
clock-names = "int";
|
||||
status = "disabled";
|
||||
};
|
||||
m4_timers17: timer@44008000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x44008000 0x400>;
|
||||
clocks = <&rcc TIM17_K>;
|
||||
clock-names = "int";
|
||||
status = "disabled";
|
||||
};
|
||||
m4_spi5: spi@44009000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x44009000 0x400>;
|
||||
clocks = <&rcc SPI5_K>;
|
||||
status = "disabled";
|
||||
};
|
||||
m4_sai1: sai@4400a000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x4400a000 0x4>;
|
||||
clocks = <&rcc SAI1_K>;
|
||||
clock-names = "sai_ck";
|
||||
status = "disabled";
|
||||
};
|
||||
m4_sai2: sai@4400b000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x4400b000 0x4>;
|
||||
clocks = <&rcc SAI2_K>;
|
||||
clock-names = "sai_ck";
|
||||
status = "disabled";
|
||||
};
|
||||
m4_sai3: sai@4400c000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x4400c000 0x4>;
|
||||
clocks = <&rcc SAI3_K>;
|
||||
clock-names = "sai_ck";
|
||||
status = "disabled";
|
||||
};
|
||||
m4_dfsdm: dfsdm@4400d000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x4400d000 0x800>;
|
||||
clocks = <&rcc DFSDM_K>, <&rcc ADFSDM_K>;
|
||||
clock-names = "dfsdm", "audio";
|
||||
status = "disabled";
|
||||
};
|
||||
m4_m_can1: can@4400e000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x4400e000 0x400>, <0x44011000 0x2800>;
|
||||
clocks = <&scmi0_clk CK_SCMI0_HSE>, <&rcc FDCAN_K>;
|
||||
clock-names = "hclk", "cclk";
|
||||
status = "disabled";
|
||||
};
|
||||
m4_m_can2: can@4400f000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x4400f000 0x400>, <0x44011000 0x2800>;
|
||||
clocks = <&scmi0_clk CK_SCMI0_HSE>, <&rcc FDCAN_K>;
|
||||
clock-names = "hclk", "cclk";
|
||||
status = "disabled";
|
||||
};
|
||||
m4_dma1: dma@48000000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x48000000 0x400>;
|
||||
clocks = <&rcc DMA1>;
|
||||
status = "disabled";
|
||||
};
|
||||
m4_dma2: dma@48001000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x48001000 0x400>;
|
||||
clocks = <&rcc DMA2>;
|
||||
status = "disabled";
|
||||
};
|
||||
m4_dmamux1: dma-router@48002000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x48002000 0x1c>;
|
||||
clocks = <&rcc DMAMUX>;
|
||||
status = "disabled";
|
||||
};
|
||||
m4_adc: adc@48003000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x48003000 0x400>;
|
||||
clocks = <&rcc ADC12>, <&rcc ADC12_K>;
|
||||
clock-names = "bus", "adc";
|
||||
status = "disabled";
|
||||
};
|
||||
m4_sdmmc3: sdmmc@48004000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x48004000 0x400>, <0x48005000 0x400>;
|
||||
clocks = <&rcc SDMMC3_K>;
|
||||
status = "disabled";
|
||||
};
|
||||
m4_usbotg_hs: usb-otg@49000000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x49000000 0x10000>;
|
||||
clocks = <&rcc USBO_K>;
|
||||
clock-names = "otg";
|
||||
status = "disabled";
|
||||
};
|
||||
m4_hash2: hash@4c002000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x4c002000 0x400>;
|
||||
clocks = <&rcc HASH2>;
|
||||
status = "disabled";
|
||||
};
|
||||
m4_rng2: rng@4c003000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x4c003000 0x400>;
|
||||
clocks = <&rcc RNG2_K>;
|
||||
status = "disabled";
|
||||
};
|
||||
m4_crc2: crc@4c004000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x4c004000 0x400>;
|
||||
clocks = <&rcc CRC2>;
|
||||
status = "disabled";
|
||||
};
|
||||
m4_cryp2: cryp@4c005000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x4c005000 0x400>;
|
||||
clocks = <&rcc CRYP2>;
|
||||
status = "disabled";
|
||||
};
|
||||
m4_dcmi: dcmi@4c006000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x4c006000 0x400>;
|
||||
clocks = <&rcc DCMI>;
|
||||
clock-names = "mclk";
|
||||
status = "disabled";
|
||||
};
|
||||
m4_lptimer2: timer@50021000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x50021000 0x400>;
|
||||
clocks = <&rcc LPTIM2_K>;
|
||||
clock-names = "mux";
|
||||
status = "disabled";
|
||||
};
|
||||
m4_lptimer3: timer@50022000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x50022000 0x400>;
|
||||
clocks = <&rcc LPTIM3_K>;
|
||||
clock-names = "mux";
|
||||
status = "disabled";
|
||||
};
|
||||
m4_lptimer4: timer@50023000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x50023000 0x400>;
|
||||
clocks = <&rcc LPTIM4_K>;
|
||||
clock-names = "mux";
|
||||
status = "disabled";
|
||||
};
|
||||
m4_lptimer5: timer@50024000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x50024000 0x400>;
|
||||
clocks = <&rcc LPTIM5_K>;
|
||||
clock-names = "mux";
|
||||
status = "disabled";
|
||||
};
|
||||
m4_sai4: sai@50027000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x50027000 0x4>;
|
||||
clocks = <&rcc SAI4_K>;
|
||||
clock-names = "sai_ck";
|
||||
status = "disabled";
|
||||
};
|
||||
m4_qspi: qspi@58003000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x58003000 0x1000>, <0x70000000 0x10000000>;
|
||||
clocks = <&rcc QSPI_K>;
|
||||
status = "disabled";
|
||||
};
|
||||
m4_ethernet0: ethernet@5800a000 {
|
||||
compatible = "rproc-srm-dev";
|
||||
reg = <0x5800a000 0x2000>;
|
||||
clock-names = "stmmaceth",
|
||||
"mac-clk-tx",
|
||||
"mac-clk-rx",
|
||||
"ethstp",
|
||||
"syscfg-clk";
|
||||
clocks = <&rcc ETHMAC>,
|
||||
<&rcc ETHTX>,
|
||||
<&rcc ETHRX>,
|
||||
<&rcc ETHSTP>,
|
||||
<&rcc SYSCFG>;
|
||||
status = "disabled";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
157
arch/arm/dts/stm32mp15-no-scmi.dtsi
Normal file
157
arch/arm/dts/stm32mp15-no-scmi.dtsi
Normal file
@ -0,0 +1,157 @@
|
||||
// SPDX-License-Identifier: (GPL-2.0+ OR BSD-3-Clause)
|
||||
/*
|
||||
* Copyright (C) STMicroelectronics 2020 - All Rights Reserved
|
||||
* Author: Gabriel Fernandez <gabriel.fernandez@st.com> for STMicroelectronics.
|
||||
*/
|
||||
|
||||
/ {
|
||||
|
||||
clocks {
|
||||
clk_hse: clk-hse {
|
||||
#clock-cells = <0>;
|
||||
compatible = "fixed-clock";
|
||||
clock-frequency = <24000000>;
|
||||
};
|
||||
|
||||
clk_hsi: clk-hsi {
|
||||
#clock-cells = <0>;
|
||||
compatible = "fixed-clock";
|
||||
clock-frequency = <64000000>;
|
||||
};
|
||||
|
||||
clk_lse: clk-lse {
|
||||
#clock-cells = <0>;
|
||||
compatible = "fixed-clock";
|
||||
clock-frequency = <32768>;
|
||||
};
|
||||
|
||||
clk_lsi: clk-lsi {
|
||||
#clock-cells = <0>;
|
||||
compatible = "fixed-clock";
|
||||
clock-frequency = <32000>;
|
||||
};
|
||||
|
||||
clk_csi: clk-csi {
|
||||
#clock-cells = <0>;
|
||||
compatible = "fixed-clock";
|
||||
clock-frequency = <4000000>;
|
||||
};
|
||||
};
|
||||
|
||||
cpus {
|
||||
cpu0: cpu@0 {
|
||||
clocks = <&rcc CK_MPU>;
|
||||
};
|
||||
|
||||
cpu1: cpu@1 {
|
||||
clocks = <&rcc CK_MPU>;
|
||||
};
|
||||
};
|
||||
|
||||
reboot {
|
||||
compatible = "syscon-reboot";
|
||||
regmap = <&rcc>;
|
||||
offset = <0x404>;
|
||||
mask = <0x1>;
|
||||
};
|
||||
|
||||
soc {
|
||||
m_can1: can@4400e000 {
|
||||
clocks = <&rcc CK_HSE>, <&rcc FDCAN_K>;
|
||||
};
|
||||
|
||||
m_can2: can@4400f000 {
|
||||
clocks = <&rcc CK_HSE>, <&rcc FDCAN_K>;
|
||||
};
|
||||
|
||||
cryp1: cryp@54001000 {
|
||||
clocks = <&rcc CRYP1>;
|
||||
resets = <&rcc CRYP1_R>;
|
||||
};
|
||||
|
||||
dsi: dsi@5a000000 {
|
||||
clocks = <&rcc DSI_K>, <&clk_hse>, <&rcc DSI_PX>;
|
||||
};
|
||||
};
|
||||
|
||||
ahb {
|
||||
m4_rproc: m4@10000000 {
|
||||
resets = <&rcc MCU_R>, <&rcc MCU_HOLD_BOOT_R>;
|
||||
|
||||
m4_system_resources {
|
||||
m4_cec: cec@40016000 {
|
||||
clocks = <&rcc CEC_K>, <&rcc CK_LSE>;
|
||||
};
|
||||
|
||||
m4_m_can1: can@4400e000 {
|
||||
clocks = <&rcc CK_HSE>, <&rcc FDCAN_K>;
|
||||
};
|
||||
|
||||
m4_m_can2: can@4400f000 {
|
||||
clocks = <&rcc CK_HSE>, <&rcc FDCAN_K>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
firmware {
|
||||
/delete-node/ scmi0;
|
||||
/delete-node/ scmi1;
|
||||
};
|
||||
/delete-node/ sram@2ffff000;
|
||||
};
|
||||
|
||||
&cec {
|
||||
clocks = <&rcc CEC_K>, <&clk_lse>;
|
||||
};
|
||||
|
||||
&gpioz {
|
||||
clocks = <&rcc GPIOZ>;
|
||||
};
|
||||
|
||||
&hash1 {
|
||||
clocks = <&rcc HASH1>;
|
||||
resets = <&rcc HASH1_R>;
|
||||
};
|
||||
|
||||
&i2c4 {
|
||||
clocks = <&rcc I2C4_K>;
|
||||
resets = <&rcc I2C4_R>;
|
||||
};
|
||||
|
||||
&i2c6 {
|
||||
clocks = <&rcc I2C6_K>;
|
||||
resets = <&rcc I2C6_R>;
|
||||
};
|
||||
|
||||
&iwdg2 {
|
||||
clocks = <&rcc IWDG2>, <&rcc CK_LSI>;
|
||||
};
|
||||
|
||||
&mdma1 {
|
||||
clocks = <&rcc MDMA>;
|
||||
resets = <&rcc MDMA_R>;
|
||||
};
|
||||
|
||||
&rcc {
|
||||
compatible = "st,stm32mp1-rcc", "syscon";
|
||||
clocks = <&clk_hse>, <&clk_hsi>, <&clk_csi>, <&clk_lse>, <&clk_lsi>;
|
||||
};
|
||||
|
||||
&rng1 {
|
||||
clocks = <&rcc RNG1_K>;
|
||||
resets = <&rcc RNG1_R>;
|
||||
};
|
||||
|
||||
&rtc {
|
||||
clocks = <&rcc RTCAPB>, <&rcc RTC>;
|
||||
};
|
||||
|
||||
&spi6 {
|
||||
clocks = <&rcc SPI6_K>;
|
||||
resets = <&rcc SPI6_R>;
|
||||
};
|
||||
|
||||
&usart1 {
|
||||
clocks = <&rcc USART1_K>;
|
||||
};
|
||||
@ -118,6 +118,45 @@
|
||||
};
|
||||
};
|
||||
|
||||
dfsdm_clkout_pins_a: dfsdm-clkout-pins-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('B', 13, AF3)>; /* DFSDM_CKOUT */
|
||||
bias-disable;
|
||||
drive-push-pull;
|
||||
slew-rate = <0>;
|
||||
};
|
||||
};
|
||||
|
||||
dfsdm_clkout_sleep_pins_a: dfsdm-clkout-sleep-pins-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('B', 13, ANALOG)>; /* DFSDM_CKOUT */
|
||||
};
|
||||
};
|
||||
|
||||
dfsdm_data1_pins_a: dfsdm-data1-pins-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('C', 3, AF3)>; /* DFSDM_DATA1 */
|
||||
};
|
||||
};
|
||||
|
||||
dfsdm_data1_sleep_pins_a: dfsdm-data1-sleep-pins-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('C', 3, ANALOG)>; /* DFSDM_DATA1 */
|
||||
};
|
||||
};
|
||||
|
||||
dfsdm_data3_pins_a: dfsdm-data3-pins-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('F', 13, AF6)>; /* DFSDM_DATA3 */
|
||||
};
|
||||
};
|
||||
|
||||
dfsdm_data3_sleep_pins_a: dfsdm-data3-sleep-pins-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('F', 13, ANALOG)>; /* DFSDM_DATA3 */
|
||||
};
|
||||
};
|
||||
|
||||
ethernet0_rgmii_pins_a: rgmii-0 {
|
||||
pins1 {
|
||||
pinmux = <STM32_PINMUX('G', 5, AF11)>, /* ETH_RGMII_CLK125 */
|
||||
@ -349,6 +388,51 @@
|
||||
};
|
||||
};
|
||||
|
||||
hdp0_pins_a: hdp0-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('I', 12, AF2)>; /* HDP0 */
|
||||
bias-disable;
|
||||
drive-push-pull;
|
||||
slew-rate = <2>;
|
||||
};
|
||||
};
|
||||
|
||||
hdp0_pins_sleep_a: hdp0-sleep-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('I', 12, ANALOG)>; /* HDP0 */
|
||||
};
|
||||
};
|
||||
|
||||
hdp6_pins_a: hdp6-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('K', 5, AF2)>; /* HDP6 */
|
||||
bias-disable;
|
||||
drive-push-pull;
|
||||
slew-rate = <2>;
|
||||
};
|
||||
};
|
||||
|
||||
hdp6_pins_sleep_a: hdp6-sleep-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('K', 5, ANALOG)>; /* HDP6 */
|
||||
};
|
||||
};
|
||||
|
||||
hdp7_pins_a: hdp7-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('K', 6, AF2)>; /* HDP7 */
|
||||
bias-disable;
|
||||
drive-push-pull;
|
||||
slew-rate = <2>;
|
||||
};
|
||||
};
|
||||
|
||||
hdp7_pins_sleep_a: hdp7-sleep-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('K', 6, ANALOG)>; /* HDP7 */
|
||||
};
|
||||
};
|
||||
|
||||
i2c1_pins_a: i2c1-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('D', 12, AF5)>, /* I2C1_SCL */
|
||||
@ -1051,6 +1135,12 @@
|
||||
};
|
||||
};
|
||||
|
||||
rtc_out2_rmp_pins_a: rtc-out2-rmp-pins-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('I', 8, ANALOG)>; /* RTC_OUT2_RMP */
|
||||
};
|
||||
};
|
||||
|
||||
sai2a_pins_a: sai2a-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('I', 5, AF10)>, /* SAI2_SCK_A */
|
||||
@ -1147,7 +1237,7 @@
|
||||
};
|
||||
};
|
||||
|
||||
sai2b_pins_c: sai2a-4 {
|
||||
sai2b_pins_c: sai2b-4 {
|
||||
pins1 {
|
||||
pinmux = <STM32_PINMUX('F', 11, AF10)>; /* SAI2_SD_B */
|
||||
bias-disable;
|
||||
@ -1437,6 +1527,24 @@
|
||||
};
|
||||
};
|
||||
|
||||
sdmmc2_d47_pins_d: sdmmc2-d47-3 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('A', 8, AF9)>, /* SDMMC2_D4 */
|
||||
<STM32_PINMUX('A', 9, AF10)>, /* SDMMC2_D5 */
|
||||
<STM32_PINMUX('E', 5, AF9)>, /* SDMMC2_D6 */
|
||||
<STM32_PINMUX('C', 7, AF10)>; /* SDMMC2_D7 */
|
||||
};
|
||||
};
|
||||
|
||||
sdmmc2_d47_sleep_pins_d: sdmmc2-d47-sleep-3 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('A', 8, ANALOG)>, /* SDMMC2_D4 */
|
||||
<STM32_PINMUX('A', 9, ANALOG)>, /* SDMMC2_D5 */
|
||||
<STM32_PINMUX('E', 5, ANALOG)>, /* SDMMC2_D6 */
|
||||
<STM32_PINMUX('C', 7, ANALOG)>; /* SDMMC2_D7 */
|
||||
};
|
||||
};
|
||||
|
||||
sdmmc3_b4_pins_a: sdmmc3-b4-0 {
|
||||
pins1 {
|
||||
pinmux = <STM32_PINMUX('F', 0, AF9)>, /* SDMMC3_D0 */
|
||||
@ -1573,10 +1681,205 @@
|
||||
};
|
||||
};
|
||||
|
||||
spi4_pins_a: spi4-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('E', 12, AF5)>, /* SPI4_SCK */
|
||||
<STM32_PINMUX('E', 6, AF5)>; /* SPI4_MOSI */
|
||||
bias-disable;
|
||||
drive-push-pull;
|
||||
slew-rate = <1>;
|
||||
};
|
||||
pins2 {
|
||||
pinmux = <STM32_PINMUX('E', 13, AF5)>; /* SPI4_MISO */
|
||||
bias-disable;
|
||||
};
|
||||
};
|
||||
|
||||
spi4_pins_b: spi4-1 {
|
||||
pins1 {
|
||||
pinmux = <STM32_PINMUX('E', 12, AF5)>, /* SPI4_SCK */
|
||||
<STM32_PINMUX('E', 14, AF5)>; /* SPI4_MOSI */
|
||||
bias-disable;
|
||||
drive-push-pull;
|
||||
slew-rate = <1>;
|
||||
};
|
||||
|
||||
pins2 {
|
||||
pinmux = <STM32_PINMUX('E', 13, AF5)>; /* SPI4_MISO */
|
||||
bias-disable;
|
||||
};
|
||||
};
|
||||
|
||||
spi4_sleep_pins_b: spi4-sleep-1 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('E', 12, ANALOG)>, /* SPI4_SCK */
|
||||
<STM32_PINMUX('E', 13, ANALOG)>, /* SPI4_MISO */
|
||||
<STM32_PINMUX('E', 14, ANALOG)>; /* SPI4_MOSI */
|
||||
};
|
||||
};
|
||||
|
||||
spi5_pins_a: spi5-0 {
|
||||
pins1 {
|
||||
pinmux = <STM32_PINMUX('F', 7, AF5)>, /* SPI5_SCK */
|
||||
<STM32_PINMUX('F', 9, AF5)>; /* SPI5_MOSI */
|
||||
bias-disable;
|
||||
drive-push-pull;
|
||||
slew-rate = <1>;
|
||||
};
|
||||
|
||||
pins2 {
|
||||
pinmux = <STM32_PINMUX('F', 8, AF5)>; /* SPI5_MISO */
|
||||
bias-disable;
|
||||
};
|
||||
};
|
||||
|
||||
spi5_sleep_pins_a: spi5-sleep-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('F', 7, ANALOG)>, /* SPI5_SCK */
|
||||
<STM32_PINMUX('F', 8, ANALOG)>, /* SPI5_MISO */
|
||||
<STM32_PINMUX('F', 9, ANALOG)>; /* SPI5_MOSI */
|
||||
};
|
||||
};
|
||||
|
||||
stusb1600_pins_a: stusb1600-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('I', 11, ANALOG)>;
|
||||
bias-pull-up;
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('I', 11, ANALOG)>;
|
||||
bias-pull-up;
|
||||
};
|
||||
};
|
||||
|
||||
uart4_pins_a: uart4-0 {
|
||||
pins1 {
|
||||
pinmux = <STM32_PINMUX('G', 11, AF6)>; /* UART4_TX */
|
||||
bias-disable;
|
||||
drive-push-pull;
|
||||
slew-rate = <0>;
|
||||
};
|
||||
pins2 {
|
||||
pinmux = <STM32_PINMUX('B', 2, AF8)>; /* UART4_RX */
|
||||
bias-disable;
|
||||
};
|
||||
};
|
||||
|
||||
uart4_idle_pins_a: uart4-idle-0 {
|
||||
pins1 {
|
||||
pinmux = <STM32_PINMUX('G', 11, ANALOG)>; /* UART4_TX */
|
||||
};
|
||||
pins2 {
|
||||
pinmux = <STM32_PINMUX('B', 2, AF8)>; /* UART4_RX */
|
||||
bias-disable;
|
||||
};
|
||||
};
|
||||
|
||||
uart4_sleep_pins_a: uart4-sleep-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('G', 11, ANALOG)>, /* UART4_TX */
|
||||
<STM32_PINMUX('B', 2, ANALOG)>; /* UART4_RX */
|
||||
};
|
||||
};
|
||||
|
||||
uart4_pins_b: uart4-1 {
|
||||
pins1 {
|
||||
pinmux = <STM32_PINMUX('D', 1, AF8)>; /* UART4_TX */
|
||||
bias-disable;
|
||||
drive-push-pull;
|
||||
slew-rate = <0>;
|
||||
};
|
||||
pins2 {
|
||||
pinmux = <STM32_PINMUX('B', 2, AF8)>; /* UART4_RX */
|
||||
bias-disable;
|
||||
};
|
||||
};
|
||||
|
||||
uart4_pins_c: uart4-2 {
|
||||
pins1 {
|
||||
pinmux = <STM32_PINMUX('G', 11, AF6)>; /* UART4_TX */
|
||||
bias-disable;
|
||||
drive-push-pull;
|
||||
slew-rate = <0>;
|
||||
};
|
||||
pins2 {
|
||||
pinmux = <STM32_PINMUX('B', 2, AF8)>; /* UART4_RX */
|
||||
bias-disable;
|
||||
};
|
||||
};
|
||||
|
||||
uart7_pins_a: uart7-0 {
|
||||
pins1 {
|
||||
pinmux = <STM32_PINMUX('E', 8, AF7)>; /* UART7_TX */
|
||||
bias-disable;
|
||||
drive-push-pull;
|
||||
slew-rate = <0>;
|
||||
};
|
||||
pins2 {
|
||||
pinmux = <STM32_PINMUX('E', 7, AF7)>, /* UART7_RX */
|
||||
<STM32_PINMUX('E', 10, AF7)>, /* UART7_CTS */
|
||||
<STM32_PINMUX('E', 9, AF7)>; /* UART7_RTS */
|
||||
bias-disable;
|
||||
};
|
||||
};
|
||||
|
||||
uart7_pins_b: uart7-1 {
|
||||
pins1 {
|
||||
pinmux = <STM32_PINMUX('F', 7, AF7)>; /* UART7_TX */
|
||||
bias-disable;
|
||||
drive-push-pull;
|
||||
slew-rate = <0>;
|
||||
};
|
||||
pins2 {
|
||||
pinmux = <STM32_PINMUX('F', 6, AF7)>; /* UART7_RX */
|
||||
bias-disable;
|
||||
};
|
||||
};
|
||||
|
||||
uart7_pins_c: uart7-2 {
|
||||
pins1 {
|
||||
pinmux = <STM32_PINMUX('E', 8, AF7)>; /* UART7_TX */
|
||||
bias-disable;
|
||||
drive-push-pull;
|
||||
slew-rate = <0>;
|
||||
};
|
||||
pins2 {
|
||||
pinmux = <STM32_PINMUX('E', 7, AF7)>; /* UART7_RX */
|
||||
bias-pull-up;
|
||||
};
|
||||
};
|
||||
|
||||
uart7_idle_pins_c: uart7-idle-2 {
|
||||
pins1 {
|
||||
pinmux = <STM32_PINMUX('E', 8, ANALOG)>; /* UART7_TX */
|
||||
};
|
||||
pins2 {
|
||||
pinmux = <STM32_PINMUX('E', 7, AF7)>; /* UART7_RX */
|
||||
bias-pull-up;
|
||||
};
|
||||
};
|
||||
|
||||
uart7_sleep_pins_c: uart7-sleep-2 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('E', 8, ANALOG)>, /* UART7_TX */
|
||||
<STM32_PINMUX('E', 7, ANALOG)>; /* UART7_RX */
|
||||
};
|
||||
};
|
||||
|
||||
uart8_pins_a: uart8-0 {
|
||||
pins1 {
|
||||
pinmux = <STM32_PINMUX('E', 1, AF8)>; /* UART8_TX */
|
||||
bias-disable;
|
||||
drive-push-pull;
|
||||
slew-rate = <0>;
|
||||
};
|
||||
pins2 {
|
||||
pinmux = <STM32_PINMUX('E', 0, AF8)>; /* UART8_RX */
|
||||
bias-disable;
|
||||
};
|
||||
};
|
||||
|
||||
uart8_rtscts_pins_a: uart8rtscts-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('G', 7, AF8)>, /* UART8_RTS */
|
||||
<STM32_PINMUX('G', 10, AF8)>; /* UART8_CTS */
|
||||
bias-disable;
|
||||
};
|
||||
};
|
||||
|
||||
@ -1628,6 +1931,47 @@
|
||||
};
|
||||
};
|
||||
|
||||
usart2_pins_c: usart2-2 {
|
||||
pins1 {
|
||||
pinmux = <STM32_PINMUX('D', 5, AF7)>, /* USART2_TX */
|
||||
<STM32_PINMUX('D', 4, AF7)>; /* USART2_RTS */
|
||||
bias-disable;
|
||||
drive-push-pull;
|
||||
slew-rate = <3>;
|
||||
};
|
||||
pins2 {
|
||||
pinmux = <STM32_PINMUX('D', 6, AF7)>, /* USART2_RX */
|
||||
<STM32_PINMUX('D', 3, AF7)>; /* USART2_CTS_NSS */
|
||||
bias-disable;
|
||||
};
|
||||
};
|
||||
|
||||
usart2_idle_pins_c: usart2-idle-2 {
|
||||
pins1 {
|
||||
pinmux = <STM32_PINMUX('D', 5, ANALOG)>, /* USART2_TX */
|
||||
<STM32_PINMUX('D', 3, ANALOG)>; /* USART2_CTS_NSS */
|
||||
};
|
||||
pins2 {
|
||||
pinmux = <STM32_PINMUX('D', 4, AF7)>; /* USART2_RTS */
|
||||
bias-disable;
|
||||
drive-push-pull;
|
||||
slew-rate = <3>;
|
||||
};
|
||||
pins3 {
|
||||
pinmux = <STM32_PINMUX('D', 6, AF7)>; /* USART2_RX */
|
||||
bias-disable;
|
||||
};
|
||||
};
|
||||
|
||||
usart2_sleep_pins_c: usart2-sleep-2 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('D', 5, ANALOG)>, /* USART2_TX */
|
||||
<STM32_PINMUX('D', 4, ANALOG)>, /* USART2_RTS */
|
||||
<STM32_PINMUX('D', 6, ANALOG)>, /* USART2_RX */
|
||||
<STM32_PINMUX('D', 3, ANALOG)>; /* USART2_CTS_NSS */
|
||||
};
|
||||
};
|
||||
|
||||
usart3_pins_a: usart3-0 {
|
||||
pins1 {
|
||||
pinmux = <STM32_PINMUX('B', 10, AF7)>; /* USART3_TX */
|
||||
@ -1641,83 +1985,85 @@
|
||||
};
|
||||
};
|
||||
|
||||
uart4_pins_a: uart4-0 {
|
||||
usart3_pins_b: usart3-1 {
|
||||
pins1 {
|
||||
pinmux = <STM32_PINMUX('G', 11, AF6)>; /* UART4_TX */
|
||||
pinmux = <STM32_PINMUX('B', 10, AF7)>, /* USART3_TX */
|
||||
<STM32_PINMUX('G', 8, AF8)>; /* USART3_RTS */
|
||||
bias-disable;
|
||||
drive-push-pull;
|
||||
slew-rate = <0>;
|
||||
};
|
||||
pins2 {
|
||||
pinmux = <STM32_PINMUX('B', 2, AF8)>; /* UART4_RX */
|
||||
pinmux = <STM32_PINMUX('B', 12, AF8)>, /* USART3_RX */
|
||||
<STM32_PINMUX('I', 10, AF8)>; /* USART3_CTS_NSS */
|
||||
bias-disable;
|
||||
};
|
||||
};
|
||||
|
||||
uart4_pins_b: uart4-1 {
|
||||
usart3_idle_pins_b: usart3-idle-1 {
|
||||
pins1 {
|
||||
pinmux = <STM32_PINMUX('D', 1, AF8)>; /* UART4_TX */
|
||||
pinmux = <STM32_PINMUX('B', 10, ANALOG)>, /* USART3_TX */
|
||||
<STM32_PINMUX('I', 10, ANALOG)>; /* USART3_CTS_NSS */
|
||||
};
|
||||
pins2 {
|
||||
pinmux = <STM32_PINMUX('G', 8, AF8)>; /* USART3_RTS */
|
||||
bias-disable;
|
||||
drive-push-pull;
|
||||
slew-rate = <0>;
|
||||
};
|
||||
pins2 {
|
||||
pinmux = <STM32_PINMUX('B', 2, AF8)>; /* UART4_RX */
|
||||
pins3 {
|
||||
pinmux = <STM32_PINMUX('B', 12, AF8)>; /* USART3_RX */
|
||||
bias-disable;
|
||||
};
|
||||
};
|
||||
|
||||
uart4_pins_c: uart4-2 {
|
||||
pins1 {
|
||||
pinmux = <STM32_PINMUX('G', 11, AF6)>; /* UART4_TX */
|
||||
bias-disable;
|
||||
drive-push-pull;
|
||||
slew-rate = <0>;
|
||||
};
|
||||
pins2 {
|
||||
pinmux = <STM32_PINMUX('B', 2, AF8)>; /* UART4_RX */
|
||||
bias-disable;
|
||||
usart3_sleep_pins_b: usart3-sleep-1 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('B', 10, ANALOG)>, /* USART3_TX */
|
||||
<STM32_PINMUX('G', 8, ANALOG)>, /* USART3_RTS */
|
||||
<STM32_PINMUX('I', 10, ANALOG)>, /* USART3_CTS_NSS */
|
||||
<STM32_PINMUX('B', 12, ANALOG)>; /* USART3_RX */
|
||||
};
|
||||
};
|
||||
|
||||
uart7_pins_a: uart7-0 {
|
||||
usart3_pins_c: usart3-2 {
|
||||
pins1 {
|
||||
pinmux = <STM32_PINMUX('E', 8, AF7)>; /* UART4_TX */
|
||||
pinmux = <STM32_PINMUX('B', 10, AF7)>, /* USART3_TX */
|
||||
<STM32_PINMUX('G', 8, AF8)>; /* USART3_RTS */
|
||||
bias-disable;
|
||||
drive-push-pull;
|
||||
slew-rate = <0>;
|
||||
};
|
||||
pins2 {
|
||||
pinmux = <STM32_PINMUX('E', 7, AF7)>, /* UART4_RX */
|
||||
<STM32_PINMUX('E', 10, AF7)>, /* UART4_CTS */
|
||||
<STM32_PINMUX('E', 9, AF7)>; /* UART4_RTS */
|
||||
bias-disable;
|
||||
pinmux = <STM32_PINMUX('B', 12, AF8)>, /* USART3_RX */
|
||||
<STM32_PINMUX('B', 13, AF7)>; /* USART3_CTS_NSS */
|
||||
bias-pull-up;
|
||||
};
|
||||
};
|
||||
|
||||
uart7_pins_b: uart7-1 {
|
||||
usart3_idle_pins_c: usart3-idle-2 {
|
||||
pins1 {
|
||||
pinmux = <STM32_PINMUX('F', 7, AF7)>; /* UART7_TX */
|
||||
pinmux = <STM32_PINMUX('B', 10, ANALOG)>, /* USART3_TX */
|
||||
<STM32_PINMUX('B', 13, ANALOG)>; /* USART3_CTS_NSS */
|
||||
};
|
||||
pins2 {
|
||||
pinmux = <STM32_PINMUX('G', 8, AF8)>; /* USART3_RTS */
|
||||
bias-disable;
|
||||
drive-push-pull;
|
||||
slew-rate = <0>;
|
||||
};
|
||||
pins2 {
|
||||
pinmux = <STM32_PINMUX('F', 6, AF7)>; /* UART7_RX */
|
||||
bias-disable;
|
||||
pins3 {
|
||||
pinmux = <STM32_PINMUX('B', 12, AF8)>; /* USART3_RX */
|
||||
bias-pull-up;
|
||||
};
|
||||
};
|
||||
|
||||
uart8_pins_a: uart8-0 {
|
||||
pins1 {
|
||||
pinmux = <STM32_PINMUX('E', 1, AF8)>; /* UART8_TX */
|
||||
bias-disable;
|
||||
drive-push-pull;
|
||||
slew-rate = <0>;
|
||||
};
|
||||
pins2 {
|
||||
pinmux = <STM32_PINMUX('E', 0, AF8)>; /* UART8_RX */
|
||||
bias-disable;
|
||||
usart3_sleep_pins_c: usart3-sleep-2 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('B', 10, ANALOG)>, /* USART3_TX */
|
||||
<STM32_PINMUX('G', 8, ANALOG)>, /* USART3_RTS */
|
||||
<STM32_PINMUX('B', 13, ANALOG)>, /* USART3_CTS_NSS */
|
||||
<STM32_PINMUX('B', 12, ANALOG)>; /* USART3_RX */
|
||||
};
|
||||
};
|
||||
|
||||
@ -1783,17 +2129,11 @@
|
||||
};
|
||||
};
|
||||
|
||||
spi4_pins_a: spi4-0 {
|
||||
spi1_sleep_pins_a: spi1-sleep-0 {
|
||||
pins {
|
||||
pinmux = <STM32_PINMUX('E', 12, AF5)>, /* SPI4_SCK */
|
||||
<STM32_PINMUX('E', 6, AF5)>; /* SPI4_MOSI */
|
||||
bias-disable;
|
||||
drive-push-pull;
|
||||
slew-rate = <1>;
|
||||
};
|
||||
pins2 {
|
||||
pinmux = <STM32_PINMUX('E', 13, AF5)>; /* SPI4_MISO */
|
||||
bias-disable;
|
||||
pinmux = <STM32_PINMUX('Z', 0, ANALOG)>, /* SPI1_SCK */
|
||||
<STM32_PINMUX('Z', 1, ANALOG)>, /* SPI1_MISO */
|
||||
<STM32_PINMUX('Z', 2, ANALOG)>; /* SPI1_MOSI */
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
@ -21,23 +21,11 @@
|
||||
pinctrl1 = &pinctrl_z;
|
||||
};
|
||||
|
||||
clocks {
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
/* need PSCI for sysreset during board_f */
|
||||
psci {
|
||||
u-boot,dm-pre-proper;
|
||||
};
|
||||
|
||||
reboot {
|
||||
u-boot,dm-pre-reloc;
|
||||
compatible = "syscon-reboot";
|
||||
regmap = <&rcc>;
|
||||
offset = <0x404>;
|
||||
mask = <0x1>;
|
||||
};
|
||||
|
||||
soc {
|
||||
u-boot,dm-pre-reloc;
|
||||
|
||||
@ -72,36 +60,6 @@
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&clk_csi {
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&clk_hsi {
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&clk_hse {
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&clk_lsi {
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&clk_lse {
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&cpu0_opp_table {
|
||||
u-boot,dm-spl;
|
||||
opp-650000000 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
opp-800000000 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
};
|
||||
|
||||
&gpioa {
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
@ -167,16 +125,44 @@
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&pwr_regulators {
|
||||
&rcc {
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&rcc {
|
||||
#ifdef CONFIG_TFABOOT
|
||||
&scmi0 {
|
||||
u-boot,dm-pre-reloc;
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
};
|
||||
|
||||
&scmi0_clk {
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&scmi0_reset {
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&scmi0_shm {
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&scmi1 {
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&scmi1_clk {
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&scmi1_shm {
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&scmi_sram {
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
#endif
|
||||
|
||||
&sdmmc1 {
|
||||
compatible = "st,stm32-sdmmc2", "arm,pl18x", "arm,primecell";
|
||||
};
|
||||
@ -190,7 +176,7 @@
|
||||
};
|
||||
|
||||
&usart1 {
|
||||
resets = <&rcc USART1_R>;
|
||||
resets = <&scmi0_reset RST_SCMI0_USART1>;
|
||||
};
|
||||
|
||||
&usart2 {
|
||||
@ -221,6 +207,63 @@
|
||||
resets = <&rcc UART8_R>;
|
||||
};
|
||||
|
||||
&usbotg_hs {
|
||||
compatible = "st,stm32mp1-hsotg", "snps,dwc2";
|
||||
/* NO MORE USE SCMI SUPPORT for BASIC boot chain */
|
||||
#ifndef CONFIG_TFABOOT
|
||||
|
||||
#include "stm32mp15-no-scmi.dtsi"
|
||||
|
||||
/ {
|
||||
clocks {
|
||||
u-boot,dm-pre-reloc;
|
||||
|
||||
clk_hse: clk-hse {
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
clk_hsi: clk-hsi {
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
clk_lse: clk-lse {
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
clk_lsi: clk-lsi {
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
clk_csi: clk-csi {
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
};
|
||||
|
||||
reboot {
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
};
|
||||
|
||||
&cpu0_opp_table {
|
||||
u-boot,dm-spl;
|
||||
opp-650000000 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
opp-800000000 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
};
|
||||
|
||||
/* only for vdd-supply in sysconf_init() */
|
||||
&pwr_regulators {
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&rcc {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
};
|
||||
|
||||
&usart1 {
|
||||
resets = <&rcc USART1_R>;
|
||||
};
|
||||
|
||||
#endif /* CONFIG_TFABOOT */
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@ -10,12 +10,20 @@
|
||||
cpus {
|
||||
cpu1: cpu@1 {
|
||||
compatible = "arm,cortex-a7";
|
||||
clock-frequency = <650000000>;
|
||||
device_type = "cpu";
|
||||
reg = <1>;
|
||||
clocks = <&scmi0_clk CK_SCMI0_MPU>;
|
||||
clock-names = "cpu";
|
||||
operating-points-v2 = <&cpu0_opp_table>;
|
||||
};
|
||||
};
|
||||
|
||||
arm-pmu {
|
||||
interrupts = <GIC_SPI 200 IRQ_TYPE_LEVEL_HIGH>,
|
||||
<GIC_SPI 201 IRQ_TYPE_LEVEL_HIGH>;
|
||||
interrupt-affinity = <&cpu0>, <&cpu1>;
|
||||
};
|
||||
|
||||
soc {
|
||||
m_can1: can@4400e000 {
|
||||
compatible = "bosch,m_can";
|
||||
@ -24,7 +32,7 @@
|
||||
interrupts = <GIC_SPI 19 IRQ_TYPE_LEVEL_HIGH>,
|
||||
<GIC_SPI 21 IRQ_TYPE_LEVEL_HIGH>;
|
||||
interrupt-names = "int0", "int1";
|
||||
clocks = <&rcc CK_HSE>, <&rcc FDCAN_K>;
|
||||
clocks = <&scmi0_clk CK_SCMI0_HSE>, <&rcc FDCAN_K>;
|
||||
clock-names = "hclk", "cclk";
|
||||
bosch,mram-cfg = <0x0 0 0 32 0 0 2 2>;
|
||||
status = "disabled";
|
||||
@ -37,7 +45,7 @@
|
||||
interrupts = <GIC_SPI 20 IRQ_TYPE_LEVEL_HIGH>,
|
||||
<GIC_SPI 22 IRQ_TYPE_LEVEL_HIGH>;
|
||||
interrupt-names = "int0", "int1";
|
||||
clocks = <&rcc CK_HSE>, <&rcc FDCAN_K>;
|
||||
clocks = <&scmi0_clk CK_SCMI0_HSE>, <&rcc FDCAN_K>;
|
||||
clock-names = "hclk", "cclk";
|
||||
bosch,mram-cfg = <0x1400 0 0 32 0 0 2 2>;
|
||||
status = "disabled";
|
||||
|
||||
@ -20,7 +20,8 @@
|
||||
dsi: dsi@5a000000 {
|
||||
compatible = "st,stm32-dsi";
|
||||
reg = <0x5a000000 0x800>;
|
||||
clocks = <&rcc DSI_K>, <&clk_hse>, <&rcc DSI_PX>;
|
||||
phy-dsi-supply = <®18>;
|
||||
clocks = <&rcc DSI_K>, <&scmi0_clk CK_SCMI0_HSE>, <&rcc DSI_PX>;
|
||||
clock-names = "pclk", "ref", "px_clk";
|
||||
resets = <&rcc DSI_R>;
|
||||
reset-names = "apb";
|
||||
|
||||
@ -16,12 +16,18 @@
|
||||
config {
|
||||
u-boot,boot-led = "heartbeat";
|
||||
u-boot,error-led = "error";
|
||||
u-boot,mmc-env-partition = "ssbl";
|
||||
u-boot,mmc-env-partition = "fip";
|
||||
st,adc_usb_pd = <&adc1 18>, <&adc1 19>;
|
||||
st,fastboot-gpios = <&gpioa 13 GPIO_ACTIVE_LOW>;
|
||||
st,stm32prog-gpios = <&gpioa 14 GPIO_ACTIVE_LOW>;
|
||||
};
|
||||
|
||||
#ifdef CONFIG_STM32MP15x_STM32IMAGE
|
||||
config {
|
||||
u-boot,mmc-env-partition = "ssbl";
|
||||
};
|
||||
|
||||
/* only needed for boot with TF-A, witout FIP support */
|
||||
firmware {
|
||||
optee {
|
||||
compatible = "linaro,optee-tz";
|
||||
@ -35,9 +41,10 @@
|
||||
no-map;
|
||||
};
|
||||
};
|
||||
#endif
|
||||
|
||||
led {
|
||||
red {
|
||||
led-red {
|
||||
label = "error";
|
||||
gpios = <&gpioa 13 GPIO_ACTIVE_LOW>;
|
||||
default-state = "off";
|
||||
@ -50,6 +57,7 @@
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
#ifndef CONFIG_TFABOOT
|
||||
&clk_hse {
|
||||
st,digbypass;
|
||||
};
|
||||
@ -65,6 +73,10 @@
|
||||
};
|
||||
};
|
||||
|
||||
&i2s2 {
|
||||
clocks = <&rcc SPI2>, <&rcc SPI2_K>, <&rcc PLL3_Q>, <&rcc PLL3_R>;
|
||||
};
|
||||
|
||||
&pmic {
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
@ -161,6 +173,10 @@
|
||||
};
|
||||
};
|
||||
|
||||
&sai2 {
|
||||
clocks = <&rcc SAI2>, <&rcc PLL3_Q>, <&rcc PLL3_R>;
|
||||
};
|
||||
|
||||
&sdmmc1 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
@ -174,6 +190,7 @@
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
};
|
||||
#endif
|
||||
|
||||
&uart4 {
|
||||
u-boot,dm-pre-reloc;
|
||||
|
||||
@ -7,6 +7,7 @@
|
||||
/dts-v1/;
|
||||
|
||||
#include "stm32mp157.dtsi"
|
||||
#include "stm32mp15xa.dtsi"
|
||||
#include "stm32mp15-pinctrl.dtsi"
|
||||
#include "stm32mp15xxac-pinctrl.dtsi"
|
||||
#include "stm32mp15xx-dkx.dtsi"
|
||||
@ -16,8 +17,9 @@
|
||||
compatible = "st,stm32mp157a-dk1", "st,stm32mp157";
|
||||
|
||||
aliases {
|
||||
ethernet0 = ðernet0;
|
||||
serial0 = &uart4;
|
||||
serial1 = &usart3;
|
||||
serial2 = &uart7;
|
||||
};
|
||||
|
||||
chosen {
|
||||
|
||||
228
arch/arm/dts/stm32mp157a-ed1-u-boot.dtsi
Normal file
228
arch/arm/dts/stm32mp157a-ed1-u-boot.dtsi
Normal file
@ -0,0 +1,228 @@
|
||||
// SPDX-License-Identifier: GPL-2.0+ OR BSD-3-Clause
|
||||
/*
|
||||
* Copyright : STMicroelectronics 2018
|
||||
*/
|
||||
|
||||
#include <dt-bindings/clock/stm32mp1-clksrc.h>
|
||||
#include "stm32mp15-u-boot.dtsi"
|
||||
#include "stm32mp15-ddr3-2x4Gb-1066-binG.dtsi"
|
||||
|
||||
/ {
|
||||
aliases {
|
||||
i2c3 = &i2c4;
|
||||
mmc0 = &sdmmc1;
|
||||
mmc1 = &sdmmc2;
|
||||
};
|
||||
|
||||
config {
|
||||
u-boot,boot-led = "heartbeat";
|
||||
u-boot,error-led = "error";
|
||||
u-boot,mmc-env-partition = "fip";
|
||||
st,fastboot-gpios = <&gpioa 13 GPIO_ACTIVE_LOW>;
|
||||
st,stm32prog-gpios = <&gpioa 14 GPIO_ACTIVE_LOW>;
|
||||
};
|
||||
|
||||
led {
|
||||
led-red {
|
||||
label = "error";
|
||||
gpios = <&gpioa 13 GPIO_ACTIVE_LOW>;
|
||||
default-state = "off";
|
||||
status = "okay";
|
||||
};
|
||||
};
|
||||
|
||||
#ifdef CONFIG_STM32MP15x_STM32IMAGE
|
||||
config {
|
||||
u-boot,mmc-env-partition = "ssbl";
|
||||
};
|
||||
|
||||
/* only needed for boot with TF-A, witout FIP support */
|
||||
firmware {
|
||||
optee {
|
||||
compatible = "linaro,optee-tz";
|
||||
method = "smc";
|
||||
};
|
||||
};
|
||||
|
||||
reserved-memory {
|
||||
optee@fe000000 {
|
||||
reg = <0xfe000000 0x02000000>;
|
||||
no-map;
|
||||
};
|
||||
};
|
||||
#endif
|
||||
};
|
||||
|
||||
#ifndef CONFIG_TFABOOT
|
||||
&clk_hse {
|
||||
st,digbypass;
|
||||
};
|
||||
|
||||
&i2c4 {
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&i2c4_pins_a {
|
||||
u-boot,dm-pre-reloc;
|
||||
pins {
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
};
|
||||
|
||||
&pmic {
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&rcc {
|
||||
st,clksrc = <
|
||||
CLK_MPU_PLL1P
|
||||
CLK_AXI_PLL2P
|
||||
CLK_MCU_PLL3P
|
||||
CLK_PLL12_HSE
|
||||
CLK_PLL3_HSE
|
||||
CLK_PLL4_HSE
|
||||
CLK_RTC_LSE
|
||||
CLK_MCO1_DISABLED
|
||||
CLK_MCO2_DISABLED
|
||||
>;
|
||||
|
||||
st,clkdiv = <
|
||||
1 /*MPU*/
|
||||
0 /*AXI*/
|
||||
0 /*MCU*/
|
||||
1 /*APB1*/
|
||||
1 /*APB2*/
|
||||
1 /*APB3*/
|
||||
1 /*APB4*/
|
||||
2 /*APB5*/
|
||||
23 /*RTC*/
|
||||
0 /*MCO1*/
|
||||
0 /*MCO2*/
|
||||
>;
|
||||
|
||||
st,pkcs = <
|
||||
CLK_CKPER_HSE
|
||||
CLK_FMC_ACLK
|
||||
CLK_QSPI_ACLK
|
||||
CLK_ETH_DISABLED
|
||||
CLK_SDMMC12_PLL4P
|
||||
CLK_DSI_DSIPLL
|
||||
CLK_STGEN_HSE
|
||||
CLK_USBPHY_HSE
|
||||
CLK_SPI2S1_PLL3Q
|
||||
CLK_SPI2S23_PLL3Q
|
||||
CLK_SPI45_HSI
|
||||
CLK_SPI6_HSI
|
||||
CLK_I2C46_HSI
|
||||
CLK_SDMMC3_PLL4P
|
||||
CLK_USBO_USBPHY
|
||||
CLK_ADC_CKPER
|
||||
CLK_CEC_LSE
|
||||
CLK_I2C12_HSI
|
||||
CLK_I2C35_HSI
|
||||
CLK_UART1_HSI
|
||||
CLK_UART24_HSI
|
||||
CLK_UART35_HSI
|
||||
CLK_UART6_HSI
|
||||
CLK_UART78_HSI
|
||||
CLK_SPDIF_PLL4P
|
||||
CLK_FDCAN_PLL4R
|
||||
CLK_SAI1_PLL3Q
|
||||
CLK_SAI2_PLL3Q
|
||||
CLK_SAI3_PLL3Q
|
||||
CLK_SAI4_PLL3Q
|
||||
CLK_RNG1_LSI
|
||||
CLK_RNG2_LSI
|
||||
CLK_LPTIM1_PCLK1
|
||||
CLK_LPTIM23_PCLK3
|
||||
CLK_LPTIM45_LSE
|
||||
>;
|
||||
|
||||
/* VCO = 1066.0 MHz => P = 266 (AXI), Q = 533 (GPU), R = 533 (DDR) */
|
||||
pll2: st,pll@1 {
|
||||
compatible = "st,stm32mp1-pll";
|
||||
reg = <1>;
|
||||
cfg = < 2 65 1 0 0 PQR(1,1,1) >;
|
||||
frac = < 0x1400 >;
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
/* VCO = 417.8 MHz => P = 209, Q = 24, R = 11 */
|
||||
pll3: st,pll@2 {
|
||||
compatible = "st,stm32mp1-pll";
|
||||
reg = <2>;
|
||||
cfg = < 1 33 1 16 36 PQR(1,1,1) >;
|
||||
frac = < 0x1a04 >;
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
/* VCO = 594.0 MHz => P = 99, Q = 74, R = 74 */
|
||||
pll4: st,pll@3 {
|
||||
compatible = "st,stm32mp1-pll";
|
||||
reg = <3>;
|
||||
cfg = < 3 98 5 7 7 PQR(1,1,1) >;
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
};
|
||||
|
||||
&sdmmc1 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&sdmmc1_b4_pins_a {
|
||||
u-boot,dm-spl;
|
||||
pins1 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
pins2 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
};
|
||||
|
||||
&sdmmc1_dir_pins_a {
|
||||
u-boot,dm-spl;
|
||||
pins1 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
pins2 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
};
|
||||
|
||||
&sdmmc2 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&sdmmc2_b4_pins_a {
|
||||
u-boot,dm-spl;
|
||||
pins1 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
pins2 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
};
|
||||
|
||||
&sdmmc2_d47_pins_a {
|
||||
u-boot,dm-spl;
|
||||
pins {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
};
|
||||
#endif
|
||||
|
||||
&uart4 {
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&uart4_pins_a {
|
||||
u-boot,dm-pre-reloc;
|
||||
pins1 {
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
pins2 {
|
||||
u-boot,dm-pre-reloc;
|
||||
/* pull-up on rx to avoid floating level */
|
||||
bias-pull-up;
|
||||
};
|
||||
};
|
||||
32
arch/arm/dts/stm32mp157a-ed1.dts
Normal file
32
arch/arm/dts/stm32mp157a-ed1.dts
Normal file
@ -0,0 +1,32 @@
|
||||
// SPDX-License-Identifier: (GPL-2.0+ OR BSD-3-Clause)
|
||||
/*
|
||||
* Copyright (C) STMicroelectronics 2019 - All Rights Reserved
|
||||
* Author: Alexandre Torgue <alexandre.torgue@st.com> for STMicroelectronics.
|
||||
*/
|
||||
/dts-v1/;
|
||||
|
||||
#include "stm32mp157.dtsi"
|
||||
#include "stm32mp15xa.dtsi"
|
||||
#include "stm32mp15-pinctrl.dtsi"
|
||||
#include "stm32mp15xxaa-pinctrl.dtsi"
|
||||
#include "stm32mp15xx-edx.dtsi"
|
||||
|
||||
/ {
|
||||
model = "STMicroelectronics STM32MP157A eval daughter";
|
||||
compatible = "st,stm32mp157a-ed1", "st,stm32mp157";
|
||||
|
||||
chosen {
|
||||
stdout-path = "serial0:115200n8";
|
||||
};
|
||||
|
||||
reserved-memory {
|
||||
gpu_reserved: gpu@f6000000 {
|
||||
reg = <0xf6000000 0x8000000>;
|
||||
no-map;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&gpu {
|
||||
contiguous-area = <&gpu_reserved>;
|
||||
};
|
||||
62
arch/arm/dts/stm32mp157a-ev1-u-boot.dtsi
Normal file
62
arch/arm/dts/stm32mp157a-ev1-u-boot.dtsi
Normal file
@ -0,0 +1,62 @@
|
||||
// SPDX-License-Identifier: GPL-2.0+ OR BSD-3-Clause
|
||||
/*
|
||||
* Copyright : STMicroelectronics 2018
|
||||
*/
|
||||
|
||||
#include "stm32mp157c-ed1-u-boot.dtsi"
|
||||
|
||||
/ {
|
||||
aliases {
|
||||
gpio26 = &stmfx_pinctrl;
|
||||
i2c1 = &i2c2;
|
||||
i2c4 = &i2c5;
|
||||
pinctrl2 = &stmfx_pinctrl;
|
||||
spi0 = &qspi;
|
||||
usb0 = &usbotg_hs;
|
||||
};
|
||||
};
|
||||
|
||||
#ifndef CONFIG_TFABOOT
|
||||
&flash0 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&qspi {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&qspi_clk_pins_a {
|
||||
u-boot,dm-spl;
|
||||
pins {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
};
|
||||
|
||||
&qspi_bk1_pins_a {
|
||||
u-boot,dm-spl;
|
||||
pins1 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
pins2 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
};
|
||||
|
||||
&qspi_bk2_pins_a {
|
||||
u-boot,dm-spl;
|
||||
pins1 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
pins2 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
};
|
||||
&sai2 {
|
||||
clocks = <&rcc SAI2>, <&rcc PLL3_Q>, <&rcc PLL3_R>;
|
||||
};
|
||||
|
||||
&sai4 {
|
||||
clocks = <&rcc SAI4>, <&rcc PLL3_Q>, <&rcc PLL3_R>;
|
||||
};
|
||||
#endif
|
||||
|
||||
88
arch/arm/dts/stm32mp157a-ev1.dts
Normal file
88
arch/arm/dts/stm32mp157a-ev1.dts
Normal file
@ -0,0 +1,88 @@
|
||||
// SPDX-License-Identifier: (GPL-2.0+ OR BSD-3-Clause)
|
||||
/*
|
||||
* Copyright (C) STMicroelectronics 2019 - All Rights Reserved
|
||||
* Author: Alexandre Torgue <alexandre.torgue@st.com> for STMicroelectronics.
|
||||
*/
|
||||
/dts-v1/;
|
||||
|
||||
#include "stm32mp157a-ed1.dts"
|
||||
#include "stm32mp15xx-evx.dtsi"
|
||||
|
||||
/ {
|
||||
model = "STMicroelectronics STM32MP157A eval daughter on eval mother";
|
||||
compatible = "st,stm32mp157a-ev1", "st,stm32mp157a-ed1", "st,stm32mp157";
|
||||
|
||||
chosen {
|
||||
stdout-path = "serial0:115200n8";
|
||||
};
|
||||
|
||||
aliases {
|
||||
serial0 = &uart4;
|
||||
serial1 = &usart3;
|
||||
};
|
||||
};
|
||||
|
||||
<dc {
|
||||
status = "okay";
|
||||
|
||||
port {
|
||||
ltdc_ep0_out: endpoint@0 {
|
||||
reg = <0>;
|
||||
remote-endpoint = <&dsi_in>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&dsi {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
status = "okay";
|
||||
|
||||
ports {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
port@0 {
|
||||
reg = <0>;
|
||||
dsi_in: endpoint {
|
||||
remote-endpoint = <<dc_ep0_out>;
|
||||
};
|
||||
};
|
||||
|
||||
port@1 {
|
||||
reg = <1>;
|
||||
dsi_out: endpoint {
|
||||
remote-endpoint = <&dsi_panel_in>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
panel_dsi: panel-dsi@0 {
|
||||
compatible = "raydium,rm68200";
|
||||
reg = <0>;
|
||||
reset-gpios = <&gpiof 15 GPIO_ACTIVE_LOW>;
|
||||
backlight = <&panel_backlight>;
|
||||
power-supply = <&v3v3>;
|
||||
status = "okay";
|
||||
|
||||
port {
|
||||
dsi_panel_in: endpoint {
|
||||
remote-endpoint = <&dsi_out>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&i2c2 {
|
||||
gt9147: goodix_ts@5d {
|
||||
compatible = "goodix,gt9147";
|
||||
reg = <0x5d>;
|
||||
panel = <&panel_dsi>;
|
||||
pinctrl-0 = <&goodix_pins>;
|
||||
pinctrl-names = "default";
|
||||
status = "okay";
|
||||
|
||||
interrupts = <14 IRQ_TYPE_EDGE_RISING>;
|
||||
interrupt-parent = <&stmfx_pinctrl>;
|
||||
};
|
||||
};
|
||||
@ -11,24 +11,35 @@
|
||||
#include "stm32mp15-pinctrl.dtsi"
|
||||
#include "stm32mp15xxac-pinctrl.dtsi"
|
||||
#include "stm32mp15xx-dkx.dtsi"
|
||||
#include <dt-bindings/rtc/rtc-stm32.h>
|
||||
|
||||
/ {
|
||||
model = "STMicroelectronics STM32MP157C-DK2 Discovery Board";
|
||||
compatible = "st,stm32mp157c-dk2", "st,stm32mp157";
|
||||
|
||||
aliases {
|
||||
ethernet0 = ðernet0;
|
||||
serial0 = &uart4;
|
||||
serial1 = &usart3;
|
||||
serial2 = &uart7;
|
||||
serial3 = &usart2;
|
||||
};
|
||||
|
||||
chosen {
|
||||
stdout-path = "serial0:115200n8";
|
||||
};
|
||||
|
||||
wifi_pwrseq: wifi-pwrseq {
|
||||
compatible = "mmc-pwrseq-simple";
|
||||
reset-gpios = <&gpioh 4 GPIO_ACTIVE_LOW>;
|
||||
};
|
||||
};
|
||||
|
||||
&cryp1 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&dsi {
|
||||
status = "okay";
|
||||
phy-dsi-supply = <®18>;
|
||||
|
||||
ports {
|
||||
port@0 {
|
||||
@ -46,7 +57,7 @@
|
||||
};
|
||||
};
|
||||
|
||||
panel@0 {
|
||||
panel_otm8009a: panel-otm8009a@0 {
|
||||
compatible = "orisetech,otm8009a";
|
||||
reg = <0>;
|
||||
reset-gpios = <&gpioe 4 GPIO_ACTIVE_LOW>;
|
||||
@ -62,6 +73,18 @@
|
||||
};
|
||||
|
||||
&i2c1 {
|
||||
touchscreen@2a {
|
||||
compatible = "focaltech,ft6236";
|
||||
reg = <0x2a>;
|
||||
interrupts = <2 2>;
|
||||
interrupt-parent = <&gpiof>;
|
||||
interrupt-controller;
|
||||
touchscreen-size-x = <480>;
|
||||
touchscreen-size-y = <800>;
|
||||
panel = <&panel_otm8009a>;
|
||||
vcc-supply = <&v3v3>;
|
||||
status = "okay";
|
||||
};
|
||||
touchscreen@38 {
|
||||
compatible = "focaltech,ft6236";
|
||||
reg = <0x38>;
|
||||
@ -70,6 +93,8 @@
|
||||
interrupt-controller;
|
||||
touchscreen-size-x = <480>;
|
||||
touchscreen-size-y = <800>;
|
||||
panel = <&panel_otm8009a>;
|
||||
vcc-supply = <&v3v3>;
|
||||
status = "okay";
|
||||
};
|
||||
};
|
||||
@ -84,3 +109,49 @@
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&rtc {
|
||||
st,lsco = <RTC_OUT2_RMP>;
|
||||
pinctrl-0 = <&rtc_out2_rmp_pins_a>;
|
||||
pinctrl-names = "default";
|
||||
};
|
||||
|
||||
/* Wifi */
|
||||
&sdmmc2 {
|
||||
arm,primecell-periphid = <0x10153180>;
|
||||
pinctrl-names = "default", "opendrain", "sleep";
|
||||
pinctrl-0 = <&sdmmc2_b4_pins_a>;
|
||||
pinctrl-1 = <&sdmmc2_b4_od_pins_a>;
|
||||
pinctrl-2 = <&sdmmc2_b4_sleep_pins_a>;
|
||||
non-removable;
|
||||
st,neg-edge;
|
||||
bus-width = <4>;
|
||||
vmmc-supply = <&v3v3>;
|
||||
mmc-pwrseq = <&wifi_pwrseq>;
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
status = "okay";
|
||||
|
||||
brcmf: bcrmf@1 {
|
||||
reg = <1>;
|
||||
compatible = "brcm,bcm4329-fmac";
|
||||
};
|
||||
};
|
||||
|
||||
/* Bluetooth */
|
||||
&usart2 {
|
||||
pinctrl-names = "default", "sleep", "idle";
|
||||
pinctrl-0 = <&usart2_pins_c>;
|
||||
pinctrl-1 = <&usart2_sleep_pins_c>;
|
||||
pinctrl-2 = <&usart2_idle_pins_c>;
|
||||
uart-has-rtscts;
|
||||
status = "okay";
|
||||
|
||||
bluetooth {
|
||||
shutdown-gpios = <&gpioz 6 GPIO_ACTIVE_HIGH>;
|
||||
compatible = "brcm,bcm43438-bt";
|
||||
max-speed = <3000000>;
|
||||
vbat-supply = <&v3v3>;
|
||||
vddio-supply = <&v3v3>;
|
||||
};
|
||||
};
|
||||
|
||||
@ -3,217 +3,4 @@
|
||||
* Copyright : STMicroelectronics 2018
|
||||
*/
|
||||
|
||||
#include <dt-bindings/clock/stm32mp1-clksrc.h>
|
||||
#include "stm32mp15-u-boot.dtsi"
|
||||
#include "stm32mp15-ddr3-2x4Gb-1066-binG.dtsi"
|
||||
|
||||
/ {
|
||||
aliases {
|
||||
i2c3 = &i2c4;
|
||||
mmc0 = &sdmmc1;
|
||||
mmc1 = &sdmmc2;
|
||||
};
|
||||
|
||||
config {
|
||||
u-boot,boot-led = "heartbeat";
|
||||
u-boot,error-led = "error";
|
||||
u-boot,mmc-env-partition = "ssbl";
|
||||
st,fastboot-gpios = <&gpioa 13 GPIO_ACTIVE_LOW>;
|
||||
st,stm32prog-gpios = <&gpioa 14 GPIO_ACTIVE_LOW>;
|
||||
};
|
||||
|
||||
firmware {
|
||||
optee {
|
||||
compatible = "linaro,optee-tz";
|
||||
method = "smc";
|
||||
};
|
||||
};
|
||||
|
||||
reserved-memory {
|
||||
optee@fe000000 {
|
||||
reg = <0xfe000000 0x02000000>;
|
||||
no-map;
|
||||
};
|
||||
};
|
||||
|
||||
led {
|
||||
red {
|
||||
label = "error";
|
||||
gpios = <&gpioa 13 GPIO_ACTIVE_LOW>;
|
||||
default-state = "off";
|
||||
status = "okay";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&clk_hse {
|
||||
st,digbypass;
|
||||
};
|
||||
|
||||
&i2c4 {
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&i2c4_pins_a {
|
||||
u-boot,dm-pre-reloc;
|
||||
pins {
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
};
|
||||
|
||||
&pmic {
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&rcc {
|
||||
st,clksrc = <
|
||||
CLK_MPU_PLL1P
|
||||
CLK_AXI_PLL2P
|
||||
CLK_MCU_PLL3P
|
||||
CLK_PLL12_HSE
|
||||
CLK_PLL3_HSE
|
||||
CLK_PLL4_HSE
|
||||
CLK_RTC_LSE
|
||||
CLK_MCO1_DISABLED
|
||||
CLK_MCO2_DISABLED
|
||||
>;
|
||||
|
||||
st,clkdiv = <
|
||||
1 /*MPU*/
|
||||
0 /*AXI*/
|
||||
0 /*MCU*/
|
||||
1 /*APB1*/
|
||||
1 /*APB2*/
|
||||
1 /*APB3*/
|
||||
1 /*APB4*/
|
||||
2 /*APB5*/
|
||||
23 /*RTC*/
|
||||
0 /*MCO1*/
|
||||
0 /*MCO2*/
|
||||
>;
|
||||
|
||||
st,pkcs = <
|
||||
CLK_CKPER_HSE
|
||||
CLK_FMC_ACLK
|
||||
CLK_QSPI_ACLK
|
||||
CLK_ETH_DISABLED
|
||||
CLK_SDMMC12_PLL4P
|
||||
CLK_DSI_DSIPLL
|
||||
CLK_STGEN_HSE
|
||||
CLK_USBPHY_HSE
|
||||
CLK_SPI2S1_PLL3Q
|
||||
CLK_SPI2S23_PLL3Q
|
||||
CLK_SPI45_HSI
|
||||
CLK_SPI6_HSI
|
||||
CLK_I2C46_HSI
|
||||
CLK_SDMMC3_PLL4P
|
||||
CLK_USBO_USBPHY
|
||||
CLK_ADC_CKPER
|
||||
CLK_CEC_LSE
|
||||
CLK_I2C12_HSI
|
||||
CLK_I2C35_HSI
|
||||
CLK_UART1_HSI
|
||||
CLK_UART24_HSI
|
||||
CLK_UART35_HSI
|
||||
CLK_UART6_HSI
|
||||
CLK_UART78_HSI
|
||||
CLK_SPDIF_PLL4P
|
||||
CLK_FDCAN_PLL4R
|
||||
CLK_SAI1_PLL3Q
|
||||
CLK_SAI2_PLL3Q
|
||||
CLK_SAI3_PLL3Q
|
||||
CLK_SAI4_PLL3Q
|
||||
CLK_RNG1_LSI
|
||||
CLK_RNG2_LSI
|
||||
CLK_LPTIM1_PCLK1
|
||||
CLK_LPTIM23_PCLK3
|
||||
CLK_LPTIM45_LSE
|
||||
>;
|
||||
|
||||
/* VCO = 1066.0 MHz => P = 266 (AXI), Q = 533 (GPU), R = 533 (DDR) */
|
||||
pll2: st,pll@1 {
|
||||
compatible = "st,stm32mp1-pll";
|
||||
reg = <1>;
|
||||
cfg = < 2 65 1 0 0 PQR(1,1,1) >;
|
||||
frac = < 0x1400 >;
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
/* VCO = 417.8 MHz => P = 209, Q = 24, R = 11 */
|
||||
pll3: st,pll@2 {
|
||||
compatible = "st,stm32mp1-pll";
|
||||
reg = <2>;
|
||||
cfg = < 1 33 1 16 36 PQR(1,1,1) >;
|
||||
frac = < 0x1a04 >;
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
/* VCO = 594.0 MHz => P = 99, Q = 74, R = 74 */
|
||||
pll4: st,pll@3 {
|
||||
compatible = "st,stm32mp1-pll";
|
||||
reg = <3>;
|
||||
cfg = < 3 98 5 7 7 PQR(1,1,1) >;
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
};
|
||||
|
||||
&sdmmc1 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&sdmmc1_b4_pins_a {
|
||||
u-boot,dm-spl;
|
||||
pins1 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
pins2 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
};
|
||||
|
||||
&sdmmc1_dir_pins_a {
|
||||
u-boot,dm-spl;
|
||||
pins1 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
pins2 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
};
|
||||
|
||||
&sdmmc2 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&sdmmc2_b4_pins_a {
|
||||
u-boot,dm-spl;
|
||||
pins1 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
pins2 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
};
|
||||
|
||||
&sdmmc2_d47_pins_a {
|
||||
u-boot,dm-spl;
|
||||
pins {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
};
|
||||
|
||||
&uart4 {
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&uart4_pins_a {
|
||||
u-boot,dm-pre-reloc;
|
||||
pins1 {
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
pins2 {
|
||||
u-boot,dm-pre-reloc;
|
||||
/* pull-up on rx to avoid floating level */
|
||||
bias-pull-up;
|
||||
};
|
||||
};
|
||||
#include "stm32mp157a-ed1-u-boot.dtsi"
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
// SPDX-License-Identifier: (GPL-2.0+ OR BSD-3-Clause)
|
||||
/*
|
||||
* Copyright (C) STMicroelectronics 2017 - All Rights Reserved
|
||||
* Author: Ludovic Barre <ludovic.barre@st.com> for STMicroelectronics.
|
||||
* Copyright (C) STMicroelectronics 2019 - All Rights Reserved
|
||||
* Author: Alexandre Torgue <alexandre.torgue@st.com> for STMicroelectronics.
|
||||
*/
|
||||
/dts-v1/;
|
||||
|
||||
@ -9,8 +9,7 @@
|
||||
#include "stm32mp15xc.dtsi"
|
||||
#include "stm32mp15-pinctrl.dtsi"
|
||||
#include "stm32mp15xxaa-pinctrl.dtsi"
|
||||
#include <dt-bindings/gpio/gpio.h>
|
||||
#include <dt-bindings/mfd/st,stpmic1.h>
|
||||
#include "stm32mp15xx-edx.dtsi"
|
||||
|
||||
/ {
|
||||
model = "STMicroelectronics STM32MP157C eval daughter";
|
||||
@ -20,360 +19,18 @@
|
||||
stdout-path = "serial0:115200n8";
|
||||
};
|
||||
|
||||
memory@c0000000 {
|
||||
device_type = "memory";
|
||||
reg = <0xC0000000 0x40000000>;
|
||||
};
|
||||
|
||||
reserved-memory {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <1>;
|
||||
ranges;
|
||||
|
||||
mcuram2: mcuram2@10000000 {
|
||||
compatible = "shared-dma-pool";
|
||||
reg = <0x10000000 0x40000>;
|
||||
gpu_reserved: gpu@f6000000 {
|
||||
reg = <0xf6000000 0x8000000>;
|
||||
no-map;
|
||||
};
|
||||
|
||||
vdev0vring0: vdev0vring0@10040000 {
|
||||
compatible = "shared-dma-pool";
|
||||
reg = <0x10040000 0x1000>;
|
||||
no-map;
|
||||
};
|
||||
|
||||
vdev0vring1: vdev0vring1@10041000 {
|
||||
compatible = "shared-dma-pool";
|
||||
reg = <0x10041000 0x1000>;
|
||||
no-map;
|
||||
};
|
||||
|
||||
vdev0buffer: vdev0buffer@10042000 {
|
||||
compatible = "shared-dma-pool";
|
||||
reg = <0x10042000 0x4000>;
|
||||
no-map;
|
||||
};
|
||||
|
||||
mcuram: mcuram@30000000 {
|
||||
compatible = "shared-dma-pool";
|
||||
reg = <0x30000000 0x40000>;
|
||||
no-map;
|
||||
};
|
||||
|
||||
retram: retram@38000000 {
|
||||
compatible = "shared-dma-pool";
|
||||
reg = <0x38000000 0x10000>;
|
||||
no-map;
|
||||
};
|
||||
|
||||
gpu_reserved: gpu@e8000000 {
|
||||
reg = <0xe8000000 0x8000000>;
|
||||
no-map;
|
||||
};
|
||||
};
|
||||
|
||||
aliases {
|
||||
serial0 = &uart4;
|
||||
};
|
||||
|
||||
sd_switch: regulator-sd_switch {
|
||||
compatible = "regulator-gpio";
|
||||
regulator-name = "sd_switch";
|
||||
regulator-min-microvolt = <1800000>;
|
||||
regulator-max-microvolt = <2900000>;
|
||||
regulator-type = "voltage";
|
||||
regulator-always-on;
|
||||
|
||||
gpios = <&gpiof 14 GPIO_ACTIVE_HIGH>;
|
||||
gpios-states = <0>;
|
||||
states = <1800000 0x1>,
|
||||
<2900000 0x0>;
|
||||
};
|
||||
};
|
||||
|
||||
&adc {
|
||||
/* ANA0, ANA1 are dedicated pins and don't need pinctrl: only in6. */
|
||||
pinctrl-0 = <&adc1_in6_pins_a>;
|
||||
pinctrl-names = "default";
|
||||
vdd-supply = <&vdd>;
|
||||
vdda-supply = <&vdda>;
|
||||
vref-supply = <&vdda>;
|
||||
status = "disabled";
|
||||
adc1: adc@0 {
|
||||
st,adc-channels = <0 1 6>;
|
||||
/* 16.5 ck_cycles sampling time */
|
||||
st,min-sample-time-nsecs = <400>;
|
||||
status = "okay";
|
||||
};
|
||||
};
|
||||
|
||||
&cpu0{
|
||||
cpu-supply = <&vddcore>;
|
||||
};
|
||||
|
||||
&cpu1{
|
||||
cpu-supply = <&vddcore>;
|
||||
};
|
||||
|
||||
&dac {
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&dac_ch1_pins_a &dac_ch2_pins_a>;
|
||||
vref-supply = <&vdda>;
|
||||
status = "disabled";
|
||||
dac1: dac@1 {
|
||||
status = "okay";
|
||||
};
|
||||
dac2: dac@2 {
|
||||
status = "okay";
|
||||
};
|
||||
};
|
||||
|
||||
&dts {
|
||||
&cryp1 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&gpu {
|
||||
contiguous-area = <&gpu_reserved>;
|
||||
};
|
||||
|
||||
&i2c4 {
|
||||
pinctrl-names = "default", "sleep";
|
||||
pinctrl-0 = <&i2c4_pins_a>;
|
||||
pinctrl-1 = <&i2c4_sleep_pins_a>;
|
||||
i2c-scl-rising-time-ns = <185>;
|
||||
i2c-scl-falling-time-ns = <20>;
|
||||
clock-frequency = <400000>;
|
||||
status = "okay";
|
||||
/* spare dmas for other usage */
|
||||
/delete-property/dmas;
|
||||
/delete-property/dma-names;
|
||||
|
||||
pmic: stpmic@33 {
|
||||
compatible = "st,stpmic1";
|
||||
reg = <0x33>;
|
||||
interrupts-extended = <&gpioa 0 IRQ_TYPE_EDGE_FALLING>;
|
||||
interrupt-controller;
|
||||
#interrupt-cells = <2>;
|
||||
status = "okay";
|
||||
|
||||
regulators {
|
||||
compatible = "st,stpmic1-regulators";
|
||||
ldo1-supply = <&v3v3>;
|
||||
ldo2-supply = <&v3v3>;
|
||||
ldo3-supply = <&vdd_ddr>;
|
||||
ldo5-supply = <&v3v3>;
|
||||
ldo6-supply = <&v3v3>;
|
||||
pwr_sw1-supply = <&bst_out>;
|
||||
pwr_sw2-supply = <&bst_out>;
|
||||
|
||||
vddcore: buck1 {
|
||||
regulator-name = "vddcore";
|
||||
regulator-min-microvolt = <1200000>;
|
||||
regulator-max-microvolt = <1350000>;
|
||||
regulator-always-on;
|
||||
regulator-initial-mode = <0>;
|
||||
regulator-over-current-protection;
|
||||
};
|
||||
|
||||
vdd_ddr: buck2 {
|
||||
regulator-name = "vdd_ddr";
|
||||
regulator-min-microvolt = <1350000>;
|
||||
regulator-max-microvolt = <1350000>;
|
||||
regulator-always-on;
|
||||
regulator-initial-mode = <0>;
|
||||
regulator-over-current-protection;
|
||||
};
|
||||
|
||||
vdd: buck3 {
|
||||
regulator-name = "vdd";
|
||||
regulator-min-microvolt = <3300000>;
|
||||
regulator-max-microvolt = <3300000>;
|
||||
regulator-always-on;
|
||||
st,mask-reset;
|
||||
regulator-initial-mode = <0>;
|
||||
regulator-over-current-protection;
|
||||
};
|
||||
|
||||
v3v3: buck4 {
|
||||
regulator-name = "v3v3";
|
||||
regulator-min-microvolt = <3300000>;
|
||||
regulator-max-microvolt = <3300000>;
|
||||
regulator-always-on;
|
||||
regulator-over-current-protection;
|
||||
regulator-initial-mode = <0>;
|
||||
};
|
||||
|
||||
vdda: ldo1 {
|
||||
regulator-name = "vdda";
|
||||
regulator-min-microvolt = <2900000>;
|
||||
regulator-max-microvolt = <2900000>;
|
||||
interrupts = <IT_CURLIM_LDO1 0>;
|
||||
};
|
||||
|
||||
v2v8: ldo2 {
|
||||
regulator-name = "v2v8";
|
||||
regulator-min-microvolt = <2800000>;
|
||||
regulator-max-microvolt = <2800000>;
|
||||
interrupts = <IT_CURLIM_LDO2 0>;
|
||||
};
|
||||
|
||||
vtt_ddr: ldo3 {
|
||||
regulator-name = "vtt_ddr";
|
||||
regulator-min-microvolt = <500000>;
|
||||
regulator-max-microvolt = <750000>;
|
||||
regulator-always-on;
|
||||
regulator-over-current-protection;
|
||||
};
|
||||
|
||||
vdd_usb: ldo4 {
|
||||
regulator-name = "vdd_usb";
|
||||
interrupts = <IT_CURLIM_LDO4 0>;
|
||||
};
|
||||
|
||||
vdd_sd: ldo5 {
|
||||
regulator-name = "vdd_sd";
|
||||
regulator-min-microvolt = <2900000>;
|
||||
regulator-max-microvolt = <2900000>;
|
||||
interrupts = <IT_CURLIM_LDO5 0>;
|
||||
regulator-boot-on;
|
||||
};
|
||||
|
||||
v1v8: ldo6 {
|
||||
regulator-name = "v1v8";
|
||||
regulator-min-microvolt = <1800000>;
|
||||
regulator-max-microvolt = <1800000>;
|
||||
interrupts = <IT_CURLIM_LDO6 0>;
|
||||
};
|
||||
|
||||
vref_ddr: vref_ddr {
|
||||
regulator-name = "vref_ddr";
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
bst_out: boost {
|
||||
regulator-name = "bst_out";
|
||||
interrupts = <IT_OCP_BOOST 0>;
|
||||
};
|
||||
|
||||
vbus_otg: pwr_sw1 {
|
||||
regulator-name = "vbus_otg";
|
||||
interrupts = <IT_OCP_OTG 0>;
|
||||
};
|
||||
|
||||
vbus_sw: pwr_sw2 {
|
||||
regulator-name = "vbus_sw";
|
||||
interrupts = <IT_OCP_SWOUT 0>;
|
||||
regulator-active-discharge = <1>;
|
||||
};
|
||||
};
|
||||
|
||||
onkey {
|
||||
compatible = "st,stpmic1-onkey";
|
||||
interrupts = <IT_PONKEY_F 0>, <IT_PONKEY_R 0>;
|
||||
interrupt-names = "onkey-falling", "onkey-rising";
|
||||
power-off-time-sec = <10>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
watchdog {
|
||||
compatible = "st,stpmic1-wdt";
|
||||
status = "disabled";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&ipcc {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&iwdg2 {
|
||||
timeout-sec = <32>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&m4_rproc {
|
||||
memory-region = <&retram>, <&mcuram>, <&mcuram2>, <&vdev0vring0>,
|
||||
<&vdev0vring1>, <&vdev0buffer>;
|
||||
mboxes = <&ipcc 0>, <&ipcc 1>, <&ipcc 2>;
|
||||
mbox-names = "vq0", "vq1", "shutdown";
|
||||
interrupt-parent = <&exti>;
|
||||
interrupts = <68 1>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&pwr_regulators {
|
||||
vdd-supply = <&vdd>;
|
||||
vdd_3v3_usbfs-supply = <&vdd_usb>;
|
||||
};
|
||||
|
||||
&rng1 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&rtc {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&sdmmc1 {
|
||||
pinctrl-names = "default", "opendrain", "sleep";
|
||||
pinctrl-0 = <&sdmmc1_b4_pins_a &sdmmc1_dir_pins_a>;
|
||||
pinctrl-1 = <&sdmmc1_b4_od_pins_a &sdmmc1_dir_pins_a>;
|
||||
pinctrl-2 = <&sdmmc1_b4_sleep_pins_a &sdmmc1_dir_sleep_pins_a>;
|
||||
cd-gpios = <&gpiog 1 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>;
|
||||
disable-wp;
|
||||
st,sig-dir;
|
||||
st,neg-edge;
|
||||
st,use-ckin;
|
||||
bus-width = <4>;
|
||||
vmmc-supply = <&vdd_sd>;
|
||||
vqmmc-supply = <&sd_switch>;
|
||||
sd-uhs-sdr12;
|
||||
sd-uhs-sdr25;
|
||||
sd-uhs-sdr50;
|
||||
sd-uhs-ddr50;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&sdmmc2 {
|
||||
pinctrl-names = "default", "opendrain", "sleep";
|
||||
pinctrl-0 = <&sdmmc2_b4_pins_a &sdmmc2_d47_pins_a>;
|
||||
pinctrl-1 = <&sdmmc2_b4_od_pins_a &sdmmc2_d47_pins_a>;
|
||||
pinctrl-2 = <&sdmmc2_b4_sleep_pins_a &sdmmc2_d47_sleep_pins_a>;
|
||||
non-removable;
|
||||
no-sd;
|
||||
no-sdio;
|
||||
st,neg-edge;
|
||||
bus-width = <8>;
|
||||
vmmc-supply = <&v3v3>;
|
||||
vqmmc-supply = <&vdd>;
|
||||
mmc-ddr-3_3v;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&timers6 {
|
||||
status = "okay";
|
||||
/* spare dmas for other usage */
|
||||
/delete-property/dmas;
|
||||
/delete-property/dma-names;
|
||||
timer@5 {
|
||||
status = "okay";
|
||||
};
|
||||
};
|
||||
|
||||
&uart4 {
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&uart4_pins_a>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&usbotg_hs {
|
||||
vbus-supply = <&vbus_otg>;
|
||||
};
|
||||
|
||||
&usbphyc_port0 {
|
||||
phy-supply = <&vdd_usb>;
|
||||
};
|
||||
|
||||
&usbphyc_port1 {
|
||||
phy-supply = <&vdd_usb>;
|
||||
};
|
||||
|
||||
@ -3,51 +3,4 @@
|
||||
* Copyright : STMicroelectronics 2018
|
||||
*/
|
||||
|
||||
#include "stm32mp157c-ed1-u-boot.dtsi"
|
||||
|
||||
/ {
|
||||
aliases {
|
||||
gpio26 = &stmfx_pinctrl;
|
||||
i2c1 = &i2c2;
|
||||
i2c4 = &i2c5;
|
||||
pinctrl2 = &stmfx_pinctrl;
|
||||
spi0 = &qspi;
|
||||
usb0 = &usbotg_hs;
|
||||
};
|
||||
};
|
||||
|
||||
&flash0 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&qspi {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&qspi_clk_pins_a {
|
||||
u-boot,dm-spl;
|
||||
pins {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
};
|
||||
|
||||
&qspi_bk1_pins_a {
|
||||
u-boot,dm-spl;
|
||||
pins1 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
pins2 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
};
|
||||
|
||||
&qspi_bk2_pins_a {
|
||||
u-boot,dm-spl;
|
||||
pins1 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
pins2 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
};
|
||||
|
||||
#include "stm32mp157a-ev1-u-boot.dtsi"
|
||||
|
||||
@ -1,13 +1,12 @@
|
||||
// SPDX-License-Identifier: (GPL-2.0+ OR BSD-3-Clause)
|
||||
/*
|
||||
* Copyright (C) STMicroelectronics 2017 - All Rights Reserved
|
||||
* Author: Ludovic Barre <ludovic.barre@st.com> for STMicroelectronics.
|
||||
* Copyright (C) STMicroelectronics 2019 - All Rights Reserved
|
||||
* Author: Alexandre Torgue <alexandre.torgue@st.com> for STMicroelectronics.
|
||||
*/
|
||||
/dts-v1/;
|
||||
|
||||
#include "stm32mp157c-ed1.dts"
|
||||
#include <dt-bindings/gpio/gpio.h>
|
||||
#include <dt-bindings/input/input.h>
|
||||
#include "stm32mp15xx-evx.dtsi"
|
||||
|
||||
/ {
|
||||
model = "STMicroelectronics STM32MP157C eval daughter on eval mother";
|
||||
@ -19,89 +18,30 @@
|
||||
|
||||
aliases {
|
||||
serial0 = &uart4;
|
||||
ethernet0 = ðernet0;
|
||||
};
|
||||
|
||||
clocks {
|
||||
clk_ext_camera: clk-ext-camera {
|
||||
#clock-cells = <0>;
|
||||
compatible = "fixed-clock";
|
||||
clock-frequency = <24000000>;
|
||||
};
|
||||
};
|
||||
|
||||
joystick {
|
||||
compatible = "gpio-keys";
|
||||
pinctrl-0 = <&joystick_pins>;
|
||||
pinctrl-names = "default";
|
||||
button-0 {
|
||||
label = "JoySel";
|
||||
linux,code = <KEY_ENTER>;
|
||||
interrupt-parent = <&stmfx_pinctrl>;
|
||||
interrupts = <0 IRQ_TYPE_EDGE_RISING>;
|
||||
};
|
||||
button-1 {
|
||||
label = "JoyDown";
|
||||
linux,code = <KEY_DOWN>;
|
||||
interrupt-parent = <&stmfx_pinctrl>;
|
||||
interrupts = <1 IRQ_TYPE_EDGE_RISING>;
|
||||
};
|
||||
button-2 {
|
||||
label = "JoyLeft";
|
||||
linux,code = <KEY_LEFT>;
|
||||
interrupt-parent = <&stmfx_pinctrl>;
|
||||
interrupts = <2 IRQ_TYPE_EDGE_RISING>;
|
||||
};
|
||||
button-3 {
|
||||
label = "JoyRight";
|
||||
linux,code = <KEY_RIGHT>;
|
||||
interrupt-parent = <&stmfx_pinctrl>;
|
||||
interrupts = <3 IRQ_TYPE_EDGE_RISING>;
|
||||
};
|
||||
button-4 {
|
||||
label = "JoyUp";
|
||||
linux,code = <KEY_UP>;
|
||||
interrupt-parent = <&stmfx_pinctrl>;
|
||||
interrupts = <4 IRQ_TYPE_EDGE_RISING>;
|
||||
};
|
||||
};
|
||||
|
||||
panel_backlight: panel-backlight {
|
||||
compatible = "gpio-backlight";
|
||||
gpios = <&gpiod 13 GPIO_ACTIVE_LOW>;
|
||||
default-on;
|
||||
status = "okay";
|
||||
serial1 = &usart3;
|
||||
};
|
||||
};
|
||||
|
||||
&cec {
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&cec_pins_a>;
|
||||
<dc {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&dcmi {
|
||||
status = "okay";
|
||||
pinctrl-names = "default", "sleep";
|
||||
pinctrl-0 = <&dcmi_pins_a>;
|
||||
pinctrl-1 = <&dcmi_sleep_pins_a>;
|
||||
|
||||
port {
|
||||
dcmi_0: endpoint {
|
||||
remote-endpoint = <&ov5640_0>;
|
||||
bus-width = <8>;
|
||||
hsync-active = <0>;
|
||||
vsync-active = <0>;
|
||||
pclk-sample = <1>;
|
||||
ltdc_ep0_out: endpoint@0 {
|
||||
reg = <0>;
|
||||
remote-endpoint = <&dsi_in>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&dsi {
|
||||
phy-dsi-supply = <®18>;
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
status = "okay";
|
||||
|
||||
ports {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
port@0 {
|
||||
reg = <0>;
|
||||
dsi_in: endpoint {
|
||||
@ -117,7 +57,7 @@
|
||||
};
|
||||
};
|
||||
|
||||
panel-dsi@0 {
|
||||
panel_dsi: panel-dsi@0 {
|
||||
compatible = "raydium,rm68200";
|
||||
reg = <0>;
|
||||
reset-gpios = <&gpiof 15 GPIO_ACTIVE_LOW>;
|
||||
@ -133,229 +73,16 @@
|
||||
};
|
||||
};
|
||||
|
||||
ðernet0 {
|
||||
status = "okay";
|
||||
pinctrl-0 = <ðernet0_rgmii_pins_a>;
|
||||
pinctrl-1 = <ðernet0_rgmii_sleep_pins_a>;
|
||||
pinctrl-names = "default", "sleep";
|
||||
phy-mode = "rgmii-id";
|
||||
max-speed = <1000>;
|
||||
phy-handle = <&phy0>;
|
||||
|
||||
mdio0 {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
compatible = "snps,dwmac-mdio";
|
||||
phy0: ethernet-phy@0 {
|
||||
reg = <0>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&fmc {
|
||||
pinctrl-names = "default", "sleep";
|
||||
pinctrl-0 = <&fmc_pins_a>;
|
||||
pinctrl-1 = <&fmc_sleep_pins_a>;
|
||||
status = "okay";
|
||||
|
||||
nand-controller@4,0 {
|
||||
status = "okay";
|
||||
|
||||
nand@0 {
|
||||
reg = <0>;
|
||||
nand-on-flash-bbt;
|
||||
#address-cells = <1>;
|
||||
#size-cells = <1>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&i2c2 {
|
||||
pinctrl-names = "default", "sleep";
|
||||
pinctrl-0 = <&i2c2_pins_a>;
|
||||
pinctrl-1 = <&i2c2_sleep_pins_a>;
|
||||
i2c-scl-rising-time-ns = <185>;
|
||||
i2c-scl-falling-time-ns = <20>;
|
||||
status = "okay";
|
||||
|
||||
ov5640: camera@3c {
|
||||
compatible = "ovti,ov5640";
|
||||
reg = <0x3c>;
|
||||
clocks = <&clk_ext_camera>;
|
||||
clock-names = "xclk";
|
||||
DOVDD-supply = <&v2v8>;
|
||||
powerdown-gpios = <&stmfx_pinctrl 18 (GPIO_ACTIVE_HIGH | GPIO_PUSH_PULL)>;
|
||||
reset-gpios = <&stmfx_pinctrl 19 (GPIO_ACTIVE_LOW | GPIO_PUSH_PULL)>;
|
||||
rotation = <180>;
|
||||
gt9147: goodix_ts@5d {
|
||||
compatible = "goodix,gt9147";
|
||||
reg = <0x5d>;
|
||||
panel = <&panel_dsi>;
|
||||
pinctrl-0 = <&goodix_pins>;
|
||||
pinctrl-names = "default";
|
||||
status = "okay";
|
||||
|
||||
port {
|
||||
ov5640_0: endpoint {
|
||||
remote-endpoint = <&dcmi_0>;
|
||||
bus-width = <8>;
|
||||
data-shift = <2>; /* lines 9:2 are used */
|
||||
hsync-active = <0>;
|
||||
vsync-active = <0>;
|
||||
pclk-sample = <1>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
stmfx: stmfx@42 {
|
||||
compatible = "st,stmfx-0300";
|
||||
reg = <0x42>;
|
||||
interrupts = <8 IRQ_TYPE_EDGE_RISING>;
|
||||
interrupt-parent = <&gpioi>;
|
||||
vdd-supply = <&v3v3>;
|
||||
|
||||
stmfx_pinctrl: pinctrl {
|
||||
compatible = "st,stmfx-0300-pinctrl";
|
||||
gpio-controller;
|
||||
#gpio-cells = <2>;
|
||||
interrupt-controller;
|
||||
#interrupt-cells = <2>;
|
||||
gpio-ranges = <&stmfx_pinctrl 0 0 24>;
|
||||
|
||||
joystick_pins: joystick-pins {
|
||||
pins = "gpio0", "gpio1", "gpio2", "gpio3", "gpio4";
|
||||
bias-pull-down;
|
||||
};
|
||||
};
|
||||
interrupts = <14 IRQ_TYPE_EDGE_RISING>;
|
||||
interrupt-parent = <&stmfx_pinctrl>;
|
||||
};
|
||||
};
|
||||
|
||||
&i2c5 {
|
||||
pinctrl-names = "default", "sleep";
|
||||
pinctrl-0 = <&i2c5_pins_a>;
|
||||
pinctrl-1 = <&i2c5_sleep_pins_a>;
|
||||
i2c-scl-rising-time-ns = <185>;
|
||||
i2c-scl-falling-time-ns = <20>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
<dc {
|
||||
status = "okay";
|
||||
|
||||
port {
|
||||
ltdc_ep0_out: endpoint@0 {
|
||||
reg = <0>;
|
||||
remote-endpoint = <&dsi_in>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&m_can1 {
|
||||
pinctrl-names = "default", "sleep";
|
||||
pinctrl-0 = <&m_can1_pins_a>;
|
||||
pinctrl-1 = <&m_can1_sleep_pins_a>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&qspi {
|
||||
pinctrl-names = "default", "sleep";
|
||||
pinctrl-0 = <&qspi_clk_pins_a &qspi_bk1_pins_a &qspi_bk2_pins_a>;
|
||||
pinctrl-1 = <&qspi_clk_sleep_pins_a &qspi_bk1_sleep_pins_a &qspi_bk2_sleep_pins_a>;
|
||||
reg = <0x58003000 0x1000>, <0x70000000 0x4000000>;
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
status = "okay";
|
||||
|
||||
flash0: mx66l51235l@0 {
|
||||
compatible = "jedec,spi-nor";
|
||||
reg = <0>;
|
||||
spi-rx-bus-width = <4>;
|
||||
spi-max-frequency = <108000000>;
|
||||
#address-cells = <1>;
|
||||
#size-cells = <1>;
|
||||
};
|
||||
|
||||
flash1: mx66l51235l@1 {
|
||||
compatible = "jedec,spi-nor";
|
||||
reg = <1>;
|
||||
spi-rx-bus-width = <4>;
|
||||
spi-max-frequency = <108000000>;
|
||||
#address-cells = <1>;
|
||||
#size-cells = <1>;
|
||||
};
|
||||
};
|
||||
|
||||
&sdmmc3 {
|
||||
pinctrl-names = "default", "opendrain", "sleep";
|
||||
pinctrl-0 = <&sdmmc3_b4_pins_a>;
|
||||
pinctrl-1 = <&sdmmc3_b4_od_pins_a>;
|
||||
pinctrl-2 = <&sdmmc3_b4_sleep_pins_a>;
|
||||
broken-cd;
|
||||
st,neg-edge;
|
||||
bus-width = <4>;
|
||||
vmmc-supply = <&v3v3>;
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
&spi1 {
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&spi1_pins_a>;
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
&timers2 {
|
||||
/* spare dmas for other usage (un-delete to enable pwm capture) */
|
||||
/delete-property/dmas;
|
||||
/delete-property/dma-names;
|
||||
status = "disabled";
|
||||
pwm {
|
||||
pinctrl-0 = <&pwm2_pins_a>;
|
||||
pinctrl-1 = <&pwm2_sleep_pins_a>;
|
||||
pinctrl-names = "default", "sleep";
|
||||
status = "okay";
|
||||
};
|
||||
timer@1 {
|
||||
status = "okay";
|
||||
};
|
||||
};
|
||||
|
||||
&timers8 {
|
||||
/delete-property/dmas;
|
||||
/delete-property/dma-names;
|
||||
status = "disabled";
|
||||
pwm {
|
||||
pinctrl-0 = <&pwm8_pins_a>;
|
||||
pinctrl-1 = <&pwm8_sleep_pins_a>;
|
||||
pinctrl-names = "default", "sleep";
|
||||
status = "okay";
|
||||
};
|
||||
timer@7 {
|
||||
status = "okay";
|
||||
};
|
||||
};
|
||||
|
||||
&timers12 {
|
||||
/delete-property/dmas;
|
||||
/delete-property/dma-names;
|
||||
status = "disabled";
|
||||
pwm {
|
||||
pinctrl-0 = <&pwm12_pins_a>;
|
||||
pinctrl-1 = <&pwm12_sleep_pins_a>;
|
||||
pinctrl-names = "default", "sleep";
|
||||
status = "okay";
|
||||
};
|
||||
timer@11 {
|
||||
status = "okay";
|
||||
};
|
||||
};
|
||||
|
||||
&usbh_ehci {
|
||||
phys = <&usbphyc_port0>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&usbotg_hs {
|
||||
pinctrl-0 = <&usbotg_hs_pins_a>;
|
||||
pinctrl-names = "default";
|
||||
phys = <&usbphyc_port1 0>;
|
||||
phy-names = "usb2-phy";
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&usbphyc {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
@ -13,9 +13,11 @@
|
||||
};
|
||||
};
|
||||
|
||||
#ifndef CONFIG_TFABOOT
|
||||
&clk_hse {
|
||||
st,digbypass;
|
||||
};
|
||||
#endif
|
||||
|
||||
&i2c2 {
|
||||
u-boot,dm-pre-reloc;
|
||||
@ -32,6 +34,7 @@
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
#ifndef CONFIG_TFABOOT
|
||||
&rcc {
|
||||
st,clksrc = <
|
||||
CLK_MPU_PLL1P
|
||||
@ -123,3 +126,4 @@
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
};
|
||||
#endif
|
||||
|
||||
6
arch/arm/dts/stm32mp157d-dk1-u-boot.dtsi
Normal file
6
arch/arm/dts/stm32mp157d-dk1-u-boot.dtsi
Normal file
@ -0,0 +1,6 @@
|
||||
// SPDX-License-Identifier: GPL-2.0+ OR BSD-3-Clause
|
||||
/*
|
||||
* Copyright : STMicroelectronics 2019
|
||||
*/
|
||||
|
||||
#include "stm32mp157a-dk1-u-boot.dtsi"
|
||||
28
arch/arm/dts/stm32mp157d-dk1.dts
Normal file
28
arch/arm/dts/stm32mp157d-dk1.dts
Normal file
@ -0,0 +1,28 @@
|
||||
// SPDX-License-Identifier: (GPL-2.0+ OR BSD-3-Clause)
|
||||
/*
|
||||
* Copyright (C) STMicroelectronics 2019 - All Rights Reserved
|
||||
* Author: Alexandre Torgue <alexandre.torgue@st.com> for STMicroelectronics.
|
||||
*/
|
||||
|
||||
/dts-v1/;
|
||||
|
||||
#include "stm32mp157.dtsi"
|
||||
#include "stm32mp15xd.dtsi"
|
||||
#include "stm32mp15-pinctrl.dtsi"
|
||||
#include "stm32mp15xxac-pinctrl.dtsi"
|
||||
#include "stm32mp15xx-dkx.dtsi"
|
||||
|
||||
/ {
|
||||
model = "STMicroelectronics STM32MP157D-DK1 Discovery Board";
|
||||
compatible = "st,stm32mp157d-dk1", "st,stm32mp157";
|
||||
|
||||
aliases {
|
||||
serial0 = &uart4;
|
||||
serial1 = &usart3;
|
||||
serial2 = &uart7;
|
||||
};
|
||||
|
||||
chosen {
|
||||
stdout-path = "serial0:115200n8";
|
||||
};
|
||||
};
|
||||
6
arch/arm/dts/stm32mp157d-ed1-u-boot.dtsi
Normal file
6
arch/arm/dts/stm32mp157d-ed1-u-boot.dtsi
Normal file
@ -0,0 +1,6 @@
|
||||
// SPDX-License-Identifier: GPL-2.0+ OR BSD-3-Clause
|
||||
/*
|
||||
* Copyright : STMicroelectronics 2019
|
||||
*/
|
||||
|
||||
#include "stm32mp157a-ed1-u-boot.dtsi"
|
||||
33
arch/arm/dts/stm32mp157d-ed1.dts
Normal file
33
arch/arm/dts/stm32mp157d-ed1.dts
Normal file
@ -0,0 +1,33 @@
|
||||
// SPDX-License-Identifier: (GPL-2.0+ OR BSD-3-Clause)
|
||||
/*
|
||||
* Copyright (C) STMicroelectronics 2019 - All Rights Reserved
|
||||
* Author: Alexandre Torgue <alexandre.torgue@st.com> for STMicroelectronics.
|
||||
*/
|
||||
/dts-v1/;
|
||||
|
||||
#include "stm32mp157.dtsi"
|
||||
#include "stm32mp15xd.dtsi"
|
||||
#include "stm32mp15-pinctrl.dtsi"
|
||||
#include "stm32mp15xxaa-pinctrl.dtsi"
|
||||
#include "stm32mp15xx-edx.dtsi"
|
||||
|
||||
/ {
|
||||
model = "STMicroelectronics STM32MP157D eval daughter";
|
||||
compatible = "st,stm32mp157d-ed1", "st,stm32mp157";
|
||||
|
||||
chosen {
|
||||
stdout-path = "serial0:115200n8";
|
||||
};
|
||||
|
||||
reserved-memory {
|
||||
gpu_reserved: gpu@f6000000 {
|
||||
reg = <0xf6000000 0x8000000>;
|
||||
no-map;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&gpu {
|
||||
contiguous-area = <&gpu_reserved>;
|
||||
status = "okay";
|
||||
};
|
||||
6
arch/arm/dts/stm32mp157d-ev1-u-boot.dtsi
Normal file
6
arch/arm/dts/stm32mp157d-ev1-u-boot.dtsi
Normal file
@ -0,0 +1,6 @@
|
||||
// SPDX-License-Identifier: GPL-2.0+ OR BSD-3-Clause
|
||||
/*
|
||||
* Copyright : STMicroelectronics 2019
|
||||
*/
|
||||
|
||||
#include "stm32mp157a-ev1-u-boot.dtsi"
|
||||
88
arch/arm/dts/stm32mp157d-ev1.dts
Normal file
88
arch/arm/dts/stm32mp157d-ev1.dts
Normal file
@ -0,0 +1,88 @@
|
||||
// SPDX-License-Identifier: (GPL-2.0+ OR BSD-3-Clause)
|
||||
/*
|
||||
* Copyright (C) STMicroelectronics 2019 - All Rights Reserved
|
||||
* Author: Alexandre Torgue <alexandre.torgue@st.com> for STMicroelectronics.
|
||||
*/
|
||||
/dts-v1/;
|
||||
|
||||
#include "stm32mp157d-ed1.dts"
|
||||
#include "stm32mp15xx-evx.dtsi"
|
||||
|
||||
/ {
|
||||
model = "STMicroelectronics STM32MP157D eval daughter on eval mother";
|
||||
compatible = "st,stm32mp157d-ev1", "st,stm32mp157d-ed1", "st,stm32mp157";
|
||||
|
||||
chosen {
|
||||
stdout-path = "serial0:115200n8";
|
||||
};
|
||||
|
||||
aliases {
|
||||
serial0 = &uart4;
|
||||
serial1 = &usart3;
|
||||
};
|
||||
};
|
||||
|
||||
<dc {
|
||||
status = "okay";
|
||||
|
||||
port {
|
||||
ltdc_ep0_out: endpoint@0 {
|
||||
reg = <0>;
|
||||
remote-endpoint = <&dsi_in>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&dsi {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
status = "okay";
|
||||
|
||||
ports {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
port@0 {
|
||||
reg = <0>;
|
||||
dsi_in: endpoint {
|
||||
remote-endpoint = <<dc_ep0_out>;
|
||||
};
|
||||
};
|
||||
|
||||
port@1 {
|
||||
reg = <1>;
|
||||
dsi_out: endpoint {
|
||||
remote-endpoint = <&dsi_panel_in>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
panel_dsi: panel-dsi@0 {
|
||||
compatible = "raydium,rm68200";
|
||||
reg = <0>;
|
||||
reset-gpios = <&gpiof 15 GPIO_ACTIVE_LOW>;
|
||||
backlight = <&panel_backlight>;
|
||||
power-supply = <&v3v3>;
|
||||
status = "okay";
|
||||
|
||||
port {
|
||||
dsi_panel_in: endpoint {
|
||||
remote-endpoint = <&dsi_out>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&i2c2 {
|
||||
gt9147: goodix_ts@5d {
|
||||
compatible = "goodix,gt9147";
|
||||
reg = <0x5d>;
|
||||
panel = <&panel_dsi>;
|
||||
pinctrl-0 = <&goodix_pins>;
|
||||
pinctrl-names = "default";
|
||||
status = "okay";
|
||||
|
||||
interrupts = <14 IRQ_TYPE_EDGE_RISING>;
|
||||
interrupt-parent = <&stmfx_pinctrl>;
|
||||
};
|
||||
};
|
||||
6
arch/arm/dts/stm32mp157f-dk2-u-boot.dtsi
Normal file
6
arch/arm/dts/stm32mp157f-dk2-u-boot.dtsi
Normal file
@ -0,0 +1,6 @@
|
||||
// SPDX-License-Identifier: GPL-2.0+ OR BSD-3-Clause
|
||||
/*
|
||||
* Copyright : STMicroelectronics 2019
|
||||
*/
|
||||
|
||||
#include "stm32mp157c-dk2-u-boot.dtsi"
|
||||
157
arch/arm/dts/stm32mp157f-dk2.dts
Normal file
157
arch/arm/dts/stm32mp157f-dk2.dts
Normal file
@ -0,0 +1,157 @@
|
||||
// SPDX-License-Identifier: (GPL-2.0+ OR BSD-3-Clause)
|
||||
/*
|
||||
* Copyright (C) STMicroelectronics 2019 - All Rights Reserved
|
||||
* Author: Alexandre Torgue <alexandre.torgue@st.com> for STMicroelectronics.
|
||||
*/
|
||||
|
||||
/dts-v1/;
|
||||
|
||||
#include "stm32mp157.dtsi"
|
||||
#include "stm32mp15xf.dtsi"
|
||||
#include "stm32mp15-pinctrl.dtsi"
|
||||
#include "stm32mp15xxac-pinctrl.dtsi"
|
||||
#include "stm32mp15xx-dkx.dtsi"
|
||||
#include <dt-bindings/rtc/rtc-stm32.h>
|
||||
|
||||
/ {
|
||||
model = "STMicroelectronics STM32MP157F-DK2 Discovery Board";
|
||||
compatible = "st,stm32mp157f-dk2", "st,stm32mp157";
|
||||
|
||||
aliases {
|
||||
serial0 = &uart4;
|
||||
serial1 = &usart3;
|
||||
serial2 = &uart7;
|
||||
serial3 = &usart2;
|
||||
};
|
||||
|
||||
chosen {
|
||||
stdout-path = "serial0:115200n8";
|
||||
};
|
||||
|
||||
wifi_pwrseq: wifi-pwrseq {
|
||||
compatible = "mmc-pwrseq-simple";
|
||||
reset-gpios = <&gpioh 4 GPIO_ACTIVE_LOW>;
|
||||
};
|
||||
};
|
||||
|
||||
&cryp1 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&dsi {
|
||||
status = "okay";
|
||||
|
||||
ports {
|
||||
port@0 {
|
||||
reg = <0>;
|
||||
dsi_in: endpoint {
|
||||
remote-endpoint = <<dc_ep1_out>;
|
||||
};
|
||||
};
|
||||
|
||||
port@1 {
|
||||
reg = <1>;
|
||||
dsi_out: endpoint {
|
||||
remote-endpoint = <&panel_in>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
panel_otm8009a: panel-otm8009a@0 {
|
||||
compatible = "orisetech,otm8009a";
|
||||
reg = <0>;
|
||||
reset-gpios = <&gpioe 4 GPIO_ACTIVE_LOW>;
|
||||
power-supply = <&v3v3>;
|
||||
status = "okay";
|
||||
|
||||
port {
|
||||
panel_in: endpoint {
|
||||
remote-endpoint = <&dsi_out>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&i2c1 {
|
||||
touchscreen@2a {
|
||||
compatible = "focaltech,ft6236";
|
||||
reg = <0x2a>;
|
||||
interrupts = <2 2>;
|
||||
interrupt-parent = <&gpiof>;
|
||||
interrupt-controller;
|
||||
touchscreen-size-x = <480>;
|
||||
touchscreen-size-y = <800>;
|
||||
panel = <&panel_otm8009a>;
|
||||
vcc-supply = <&v3v3>;
|
||||
status = "okay";
|
||||
};
|
||||
touchscreen@38 {
|
||||
compatible = "focaltech,ft6236";
|
||||
reg = <0x38>;
|
||||
interrupts = <2 2>;
|
||||
interrupt-parent = <&gpiof>;
|
||||
interrupt-controller;
|
||||
touchscreen-size-x = <480>;
|
||||
touchscreen-size-y = <800>;
|
||||
panel = <&panel_otm8009a>;
|
||||
vcc-supply = <&v3v3>;
|
||||
status = "okay";
|
||||
};
|
||||
};
|
||||
|
||||
<dc {
|
||||
status = "okay";
|
||||
|
||||
port {
|
||||
ltdc_ep1_out: endpoint@1 {
|
||||
reg = <1>;
|
||||
remote-endpoint = <&dsi_in>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&rtc {
|
||||
st,lsco = <RTC_OUT2_RMP>;
|
||||
pinctrl-0 = <&rtc_out2_rmp_pins_a>;
|
||||
pinctrl-names = "default";
|
||||
};
|
||||
|
||||
/* Wifi */
|
||||
&sdmmc2 {
|
||||
arm,primecell-periphid = <0x10153180>;
|
||||
pinctrl-names = "default", "opendrain", "sleep";
|
||||
pinctrl-0 = <&sdmmc2_b4_pins_a>;
|
||||
pinctrl-1 = <&sdmmc2_b4_od_pins_a>;
|
||||
pinctrl-2 = <&sdmmc2_b4_sleep_pins_a>;
|
||||
non-removable;
|
||||
st,neg-edge;
|
||||
bus-width = <4>;
|
||||
vmmc-supply = <&v3v3>;
|
||||
mmc-pwrseq = <&wifi_pwrseq>;
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
status = "okay";
|
||||
|
||||
brcmf: bcrmf@1 {
|
||||
reg = <1>;
|
||||
compatible = "brcm,bcm4329-fmac";
|
||||
};
|
||||
};
|
||||
|
||||
/* Bluetooth */
|
||||
&usart2 {
|
||||
pinctrl-names = "default", "sleep", "idle";
|
||||
pinctrl-0 = <&usart2_pins_c>;
|
||||
pinctrl-1 = <&usart2_sleep_pins_c>;
|
||||
pinctrl-2 = <&usart2_idle_pins_c>;
|
||||
uart-has-rtscts;
|
||||
status = "okay";
|
||||
|
||||
bluetooth {
|
||||
shutdown-gpios = <&gpioz 6 GPIO_ACTIVE_HIGH>;
|
||||
compatible = "brcm,bcm43438-bt";
|
||||
max-speed = <3000000>;
|
||||
vbat-supply = <&v3v3>;
|
||||
vddio-supply = <&v3v3>;
|
||||
};
|
||||
};
|
||||
6
arch/arm/dts/stm32mp157f-ed1-u-boot.dtsi
Normal file
6
arch/arm/dts/stm32mp157f-ed1-u-boot.dtsi
Normal file
@ -0,0 +1,6 @@
|
||||
// SPDX-License-Identifier: GPL-2.0+ OR BSD-3-Clause
|
||||
/*
|
||||
* Copyright : STMicroelectronics 2019
|
||||
*/
|
||||
|
||||
#include "stm32mp157c-ed1-u-boot.dtsi"
|
||||
37
arch/arm/dts/stm32mp157f-ed1.dts
Normal file
37
arch/arm/dts/stm32mp157f-ed1.dts
Normal file
@ -0,0 +1,37 @@
|
||||
// SPDX-License-Identifier: (GPL-2.0+ OR BSD-3-Clause)
|
||||
/*
|
||||
* Copyright (C) STMicroelectronics 2019 - All Rights Reserved
|
||||
* Author: Alexandre Torgue <alexandre.torgue@st.com> for STMicroelectronics.
|
||||
*/
|
||||
/dts-v1/;
|
||||
|
||||
#include "stm32mp157.dtsi"
|
||||
#include "stm32mp15xf.dtsi"
|
||||
#include "stm32mp15-pinctrl.dtsi"
|
||||
#include "stm32mp15xxaa-pinctrl.dtsi"
|
||||
#include "stm32mp15xx-edx.dtsi"
|
||||
|
||||
/ {
|
||||
model = "STMicroelectronics STM32MP157F eval daughter";
|
||||
compatible = "st,stm32mp157f-ed1", "st,stm32mp157";
|
||||
|
||||
chosen {
|
||||
stdout-path = "serial0:115200n8";
|
||||
};
|
||||
|
||||
reserved-memory {
|
||||
gpu_reserved: gpu@f6000000 {
|
||||
reg = <0xf6000000 0x8000000>;
|
||||
no-map;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&cryp1 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&gpu {
|
||||
contiguous-area = <&gpu_reserved>;
|
||||
status = "okay";
|
||||
};
|
||||
6
arch/arm/dts/stm32mp157f-ev1-u-boot.dtsi
Normal file
6
arch/arm/dts/stm32mp157f-ev1-u-boot.dtsi
Normal file
@ -0,0 +1,6 @@
|
||||
// SPDX-License-Identifier: GPL-2.0+ OR BSD-3-Clause
|
||||
/*
|
||||
* Copyright : STMicroelectronics 2019
|
||||
*/
|
||||
|
||||
#include "stm32mp157c-ev1-u-boot.dtsi"
|
||||
89
arch/arm/dts/stm32mp157f-ev1.dts
Normal file
89
arch/arm/dts/stm32mp157f-ev1.dts
Normal file
@ -0,0 +1,89 @@
|
||||
// SPDX-License-Identifier: (GPL-2.0+ OR BSD-3-Clause)
|
||||
/*
|
||||
* Copyright (C) STMicroelectronics 2019 - All Rights Reserved
|
||||
* Author: Alexandre Torgue <alexandre.torgue@st.com> for STMicroelectronics.
|
||||
*/
|
||||
/dts-v1/;
|
||||
|
||||
#include "stm32mp157f-ed1.dts"
|
||||
#include "stm32mp15xx-evx.dtsi"
|
||||
#include <dt-bindings/input/input.h>
|
||||
|
||||
/ {
|
||||
model = "STMicroelectronics STM32MP157F eval daughter on eval mother";
|
||||
compatible = "st,stm32mp157f-ev1", "st,stm32mp157f-ed1", "st,stm32mp157";
|
||||
|
||||
chosen {
|
||||
stdout-path = "serial0:115200n8";
|
||||
};
|
||||
|
||||
aliases {
|
||||
serial0 = &uart4;
|
||||
serial1 = &usart3;
|
||||
};
|
||||
};
|
||||
|
||||
<dc {
|
||||
status = "okay";
|
||||
|
||||
port {
|
||||
ltdc_ep0_out: endpoint@0 {
|
||||
reg = <0>;
|
||||
remote-endpoint = <&dsi_in>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&dsi {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
status = "okay";
|
||||
|
||||
ports {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
port@0 {
|
||||
reg = <0>;
|
||||
dsi_in: endpoint {
|
||||
remote-endpoint = <<dc_ep0_out>;
|
||||
};
|
||||
};
|
||||
|
||||
port@1 {
|
||||
reg = <1>;
|
||||
dsi_out: endpoint {
|
||||
remote-endpoint = <&dsi_panel_in>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
panel_dsi: panel-dsi@0 {
|
||||
compatible = "raydium,rm68200";
|
||||
reg = <0>;
|
||||
reset-gpios = <&gpiof 15 GPIO_ACTIVE_LOW>;
|
||||
backlight = <&panel_backlight>;
|
||||
power-supply = <&v3v3>;
|
||||
status = "okay";
|
||||
|
||||
port {
|
||||
dsi_panel_in: endpoint {
|
||||
remote-endpoint = <&dsi_out>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&i2c2 {
|
||||
gt9147: goodix_ts@5d {
|
||||
compatible = "goodix,gt9147";
|
||||
reg = <0x5d>;
|
||||
panel = <&panel_dsi>;
|
||||
pinctrl-0 = <&goodix_pins>;
|
||||
pinctrl-names = "default";
|
||||
status = "okay";
|
||||
|
||||
interrupts = <14 IRQ_TYPE_EDGE_RISING>;
|
||||
interrupt-parent = <&stmfx_pinctrl>;
|
||||
};
|
||||
};
|
||||
13
arch/arm/dts/stm32mp15xa.dtsi
Normal file
13
arch/arm/dts/stm32mp15xa.dtsi
Normal file
@ -0,0 +1,13 @@
|
||||
// SPDX-License-Identifier: (GPL-2.0+ OR BSD-3-Clause)
|
||||
/*
|
||||
* Copyright (C) STMicroelectronics 2019 - All Rights Reserved
|
||||
* Author: Alexandre Torgue <alexandre.torgue@st.com> for STMicroelectronics.
|
||||
*/
|
||||
|
||||
&cpu0_opp_table {
|
||||
opp-650000000 {
|
||||
opp-hz = /bits/ 64 <650000000>;
|
||||
opp-microvolt = <1200000>;
|
||||
opp-supported-hw = <0x1>;
|
||||
};
|
||||
};
|
||||
@ -4,14 +4,16 @@
|
||||
* Author: Alexandre Torgue <alexandre.torgue@st.com> for STMicroelectronics.
|
||||
*/
|
||||
|
||||
#include "stm32mp15xa.dtsi"
|
||||
|
||||
/ {
|
||||
soc {
|
||||
cryp1: cryp@54001000 {
|
||||
compatible = "st,stm32mp1-cryp";
|
||||
reg = <0x54001000 0x400>;
|
||||
interrupts = <GIC_SPI 79 IRQ_TYPE_LEVEL_HIGH>;
|
||||
clocks = <&rcc CRYP1>;
|
||||
resets = <&rcc CRYP1_R>;
|
||||
clocks = <&scmi0_clk CK_SCMI0_CRYP1>;
|
||||
resets = <&scmi0_reset RST_SCMI0_CRYP1>;
|
||||
status = "disabled";
|
||||
};
|
||||
};
|
||||
|
||||
42
arch/arm/dts/stm32mp15xd.dtsi
Normal file
42
arch/arm/dts/stm32mp15xd.dtsi
Normal file
@ -0,0 +1,42 @@
|
||||
// SPDX-License-Identifier: (GPL-2.0+ OR BSD-3-Clause)
|
||||
/*
|
||||
* Copyright (C) STMicroelectronics 2019 - All Rights Reserved
|
||||
* Author: Alexandre Torgue <alexandre.torgue@st.com> for STMicroelectronics.
|
||||
*/
|
||||
|
||||
&cpu0_opp_table {
|
||||
opp-800000000 {
|
||||
opp-hz = /bits/ 64 <800000000>;
|
||||
opp-microvolt = <1350000>;
|
||||
opp-supported-hw = <0x2>;
|
||||
};
|
||||
opp-400000000 {
|
||||
opp-hz = /bits/ 64 <400000000>;
|
||||
opp-microvolt = <1200000>;
|
||||
opp-supported-hw = <0x2>;
|
||||
opp-suspend;
|
||||
};
|
||||
};
|
||||
|
||||
&cpu_thermal {
|
||||
trips {
|
||||
cpu-crit {
|
||||
temperature = <105000>;
|
||||
hysteresis = <0>;
|
||||
type = "critical";
|
||||
};
|
||||
|
||||
cpu_alert: cpu-alert {
|
||||
temperature = <95000>;
|
||||
hysteresis = <10000>;
|
||||
type = "passive";
|
||||
};
|
||||
};
|
||||
|
||||
cooling-maps {
|
||||
map0 {
|
||||
trip = <&cpu_alert>;
|
||||
cooling-device = <&cpu0 1 1>;
|
||||
};
|
||||
};
|
||||
};
|
||||
20
arch/arm/dts/stm32mp15xf.dtsi
Normal file
20
arch/arm/dts/stm32mp15xf.dtsi
Normal file
@ -0,0 +1,20 @@
|
||||
// SPDX-License-Identifier: (GPL-2.0+ OR BSD-3-Clause)
|
||||
/*
|
||||
* Copyright (C) STMicroelectronics 2019 - All Rights Reserved
|
||||
* Author: Alexandre Torgue <alexandre.torgue@st.com> for STMicroelectronics.
|
||||
*/
|
||||
|
||||
#include "stm32mp15xd.dtsi"
|
||||
|
||||
/ {
|
||||
soc {
|
||||
cryp1: cryp@54001000 {
|
||||
compatible = "st,stm32mp1-cryp";
|
||||
reg = <0x54001000 0x400>;
|
||||
interrupts = <GIC_SPI 79 IRQ_TYPE_LEVEL_HIGH>;
|
||||
clocks = <&scmi0_clk CK_SCMI0_CRYP1>;
|
||||
resets = <&scmi0_reset RST_SCMI0_CRYP1>;
|
||||
status = "disabled";
|
||||
};
|
||||
};
|
||||
};
|
||||
@ -171,6 +171,7 @@
|
||||
};
|
||||
};
|
||||
|
||||
#ifndef CONFIG_TFABOOT
|
||||
&rcc {
|
||||
st,clksrc = <
|
||||
CLK_MPU_PLL1P
|
||||
@ -262,6 +263,7 @@
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
};
|
||||
#endif
|
||||
|
||||
&sdmmc1 {
|
||||
u-boot,dm-spl;
|
||||
|
||||
@ -70,6 +70,7 @@
|
||||
};
|
||||
};
|
||||
|
||||
#ifndef CONFIG_TFABOOT
|
||||
&rcc {
|
||||
st,clksrc = <
|
||||
CLK_MPU_PLL1P
|
||||
@ -161,3 +162,4 @@
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
};
|
||||
#endif
|
||||
@ -4,10 +4,16 @@
|
||||
* Author: Alexandre Torgue <alexandre.torgue@st.com> for STMicroelectronics.
|
||||
*/
|
||||
|
||||
#include "stm32mp15-m4-srm.dtsi"
|
||||
#include "stm32mp15-m4-srm-pinctrl.dtsi"
|
||||
#include <dt-bindings/gpio/gpio.h>
|
||||
#include <dt-bindings/mfd/st,stpmic1.h>
|
||||
|
||||
/ {
|
||||
aliases {
|
||||
ethernet0 = ðernet0;
|
||||
};
|
||||
|
||||
memory@c0000000 {
|
||||
device_type = "memory";
|
||||
reg = <0xc0000000 0x20000000>;
|
||||
@ -62,7 +68,7 @@
|
||||
|
||||
led {
|
||||
compatible = "gpio-leds";
|
||||
blue {
|
||||
led-blue {
|
||||
label = "heartbeat";
|
||||
gpios = <&gpiod 11 GPIO_ACTIVE_HIGH>;
|
||||
linux,default-trigger = "heartbeat";
|
||||
@ -72,7 +78,7 @@
|
||||
|
||||
sound {
|
||||
compatible = "audio-graph-card";
|
||||
label = "STM32MP1-DK";
|
||||
label = "STM32MP15-DK";
|
||||
routing =
|
||||
"Playback" , "MCLK",
|
||||
"Capture" , "MCLK",
|
||||
@ -80,6 +86,25 @@
|
||||
dais = <&sai2a_port &sai2b_port &i2s2_port>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
usb_phy_tuning: usb-phy-tuning {
|
||||
st,hs-dc-level = <2>;
|
||||
st,fs-rftime-tuning;
|
||||
st,hs-rftime-reduction;
|
||||
st,hs-current-trim = <15>;
|
||||
st,hs-impedance-trim = <1>;
|
||||
st,squelch-level = <3>;
|
||||
st,hs-rx-offset = <2>;
|
||||
st,no-lsfs-sc;
|
||||
};
|
||||
|
||||
vin: vin {
|
||||
compatible = "regulator-fixed";
|
||||
regulator-name = "vin";
|
||||
regulator-min-microvolt = <5000000>;
|
||||
regulator-max-microvolt = <5000000>;
|
||||
regulator-always-on;
|
||||
};
|
||||
};
|
||||
|
||||
&adc {
|
||||
@ -116,10 +141,6 @@
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&dts {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&cpu0{
|
||||
cpu-supply = <&vddcore>;
|
||||
};
|
||||
@ -128,6 +149,22 @@
|
||||
cpu-supply = <&vddcore>;
|
||||
};
|
||||
|
||||
&crc1 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&dma1 {
|
||||
sram = <&dma_pool>;
|
||||
};
|
||||
|
||||
&dma2 {
|
||||
sram = <&dma_pool>;
|
||||
};
|
||||
|
||||
&dts {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
ðernet0 {
|
||||
status = "okay";
|
||||
pinctrl-0 = <ðernet0_rgmii_pins_a>;
|
||||
@ -136,6 +173,8 @@
|
||||
phy-mode = "rgmii-id";
|
||||
max-speed = <1000>;
|
||||
phy-handle = <&phy0>;
|
||||
nvmem-cells = <ðernet_mac_address>;
|
||||
nvmem-cell-names = "mac-address";
|
||||
|
||||
mdio0 {
|
||||
#address-cells = <1>;
|
||||
@ -151,6 +190,10 @@
|
||||
contiguous-area = <&gpu_reserved>;
|
||||
};
|
||||
|
||||
&hash1 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&i2c1 {
|
||||
pinctrl-names = "default", "sleep";
|
||||
pinctrl-0 = <&i2c1_pins_a>;
|
||||
@ -238,37 +281,52 @@
|
||||
/delete-property/dmas;
|
||||
/delete-property/dma-names;
|
||||
|
||||
typec: stusb1600@28 {
|
||||
stusb1600@28 {
|
||||
compatible = "st,stusb1600";
|
||||
reg = <0x28>;
|
||||
interrupts = <11 IRQ_TYPE_EDGE_FALLING>;
|
||||
interrupt-parent = <&gpioi>;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&stusb1600_pins_a>;
|
||||
|
||||
status = "okay";
|
||||
vdd-supply = <&vin>;
|
||||
|
||||
typec_con: connector {
|
||||
connector {
|
||||
compatible = "usb-c-connector";
|
||||
label = "USB-C";
|
||||
power-role = "sink";
|
||||
power-opmode = "default";
|
||||
power-role = "dual";
|
||||
typec-power-opmode = "default";
|
||||
|
||||
port {
|
||||
con_usbotg_hs_ep: endpoint {
|
||||
remote-endpoint = <&usbotg_hs_ep>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
pmic: stpmic@33 {
|
||||
compatible = "st,stpmic1";
|
||||
reg = <0x33>;
|
||||
interrupts-extended = <&gpioa 0 IRQ_TYPE_EDGE_FALLING>;
|
||||
interrupts-extended = <&exti_pwr 55 IRQ_TYPE_EDGE_FALLING>;
|
||||
interrupt-controller;
|
||||
#interrupt-cells = <2>;
|
||||
status = "okay";
|
||||
|
||||
regulators {
|
||||
compatible = "st,stpmic1-regulators";
|
||||
buck1-supply = <&vin>;
|
||||
buck2-supply = <&vin>;
|
||||
buck3-supply = <&vin>;
|
||||
buck4-supply = <&vin>;
|
||||
ldo1-supply = <&v3v3>;
|
||||
ldo2-supply = <&vin>;
|
||||
ldo3-supply = <&vdd_ddr>;
|
||||
ldo4-supply = <&vin>;
|
||||
ldo5-supply = <&vin>;
|
||||
ldo6-supply = <&v3v3>;
|
||||
vref_ddr-supply = <&vin>;
|
||||
boost-supply = <&vin>;
|
||||
pwr_sw1-supply = <&bst_out>;
|
||||
pwr_sw2-supply = <&bst_out>;
|
||||
|
||||
@ -357,23 +415,24 @@
|
||||
vref_ddr: vref_ddr {
|
||||
regulator-name = "vref_ddr";
|
||||
regulator-always-on;
|
||||
regulator-over-current-protection;
|
||||
};
|
||||
|
||||
bst_out: boost {
|
||||
bst_out: boost {
|
||||
regulator-name = "bst_out";
|
||||
interrupts = <IT_OCP_BOOST 0>;
|
||||
};
|
||||
};
|
||||
|
||||
vbus_otg: pwr_sw1 {
|
||||
regulator-name = "vbus_otg";
|
||||
interrupts = <IT_OCP_OTG 0>;
|
||||
};
|
||||
};
|
||||
|
||||
vbus_sw: pwr_sw2 {
|
||||
vbus_sw: pwr_sw2 {
|
||||
regulator-name = "vbus_sw";
|
||||
interrupts = <IT_OCP_SWOUT 0>;
|
||||
regulator-active-discharge = <1>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
onkey {
|
||||
@ -391,6 +450,19 @@
|
||||
};
|
||||
};
|
||||
|
||||
&i2c5 {
|
||||
pinctrl-names = "default", "sleep";
|
||||
pinctrl-0 = <&i2c5_pins_a>;
|
||||
pinctrl-1 = <&i2c5_sleep_pins_a>;
|
||||
i2c-scl-rising-time-ns = <185>;
|
||||
i2c-scl-falling-time-ns = <20>;
|
||||
clock-frequency = <400000>;
|
||||
/* spare dmas for other usage */
|
||||
/delete-property/dmas;
|
||||
/delete-property/dma-names;
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
&i2s2 {
|
||||
clocks = <&rcc SPI2>, <&rcc SPI2_K>, <&rcc PLL3_Q>, <&rcc PLL3_R>;
|
||||
clock-names = "pclk", "i2sclk", "x8k", "x11k";
|
||||
@ -438,6 +510,7 @@
|
||||
mbox-names = "vq0", "vq1", "shutdown";
|
||||
interrupt-parent = <&exti>;
|
||||
interrupts = <68 1>;
|
||||
wakeup-source;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
@ -465,8 +538,6 @@
|
||||
sai2a: audio-controller@4400b004 {
|
||||
#clock-cells = <0>;
|
||||
dma-names = "tx";
|
||||
clocks = <&rcc SAI2_K>;
|
||||
clock-names = "sai_ck";
|
||||
status = "okay";
|
||||
|
||||
sai2a_port: port {
|
||||
@ -524,6 +595,27 @@
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
&spi4 {
|
||||
pinctrl-names = "default", "sleep";
|
||||
pinctrl-0 = <&spi4_pins_b>;
|
||||
pinctrl-1 = <&spi4_sleep_pins_b>;
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
&spi5 {
|
||||
pinctrl-names = "default", "sleep";
|
||||
pinctrl-0 = <&spi5_pins_a>;
|
||||
pinctrl-1 = <&spi5_sleep_pins_a>;
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
&sram {
|
||||
dma_pool: dma_pool@0 {
|
||||
reg = <0x50000 0x10000>;
|
||||
pool;
|
||||
};
|
||||
};
|
||||
|
||||
&timers1 {
|
||||
/* spare dmas for other usage */
|
||||
/delete-property/dmas;
|
||||
@ -610,21 +702,50 @@
|
||||
};
|
||||
|
||||
&uart4 {
|
||||
pinctrl-names = "default";
|
||||
pinctrl-names = "default", "sleep", "idle";
|
||||
pinctrl-0 = <&uart4_pins_a>;
|
||||
pinctrl-1 = <&uart4_sleep_pins_a>;
|
||||
pinctrl-2 = <&uart4_idle_pins_a>;
|
||||
/delete-property/dmas;
|
||||
/delete-property/dma-names;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&uart7 {
|
||||
pinctrl-names = "default", "sleep", "idle";
|
||||
pinctrl-0 = <&uart7_pins_c>;
|
||||
pinctrl-1 = <&uart7_sleep_pins_c>;
|
||||
pinctrl-2 = <&uart7_idle_pins_c>;
|
||||
/delete-property/dmas;
|
||||
/delete-property/dma-names;
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
&usart3 {
|
||||
pinctrl-names = "default", "sleep", "idle";
|
||||
pinctrl-0 = <&usart3_pins_c>;
|
||||
pinctrl-1 = <&usart3_sleep_pins_c>;
|
||||
pinctrl-2 = <&usart3_idle_pins_c>;
|
||||
uart-has-rtscts;
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
&usbh_ehci {
|
||||
phys = <&usbphyc_port0>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&usbotg_hs {
|
||||
dr_mode = "peripheral";
|
||||
phys = <&usbphyc_port1 0>;
|
||||
phy-names = "usb2-phy";
|
||||
usb-role-switch;
|
||||
status = "okay";
|
||||
|
||||
port {
|
||||
usbotg_hs_ep: endpoint {
|
||||
remote-endpoint = <&con_usbotg_hs_ep>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&usbphyc {
|
||||
@ -633,10 +754,12 @@
|
||||
|
||||
&usbphyc_port0 {
|
||||
phy-supply = <&vdd_usb>;
|
||||
st,phy-tuning = <&usb_phy_tuning>;
|
||||
};
|
||||
|
||||
&usbphyc_port1 {
|
||||
phy-supply = <&vdd_usb>;
|
||||
st,phy-tuning = <&usb_phy_tuning>;
|
||||
};
|
||||
|
||||
&vrefbuf {
|
||||
|
||||
413
arch/arm/dts/stm32mp15xx-edx.dtsi
Normal file
413
arch/arm/dts/stm32mp15xx-edx.dtsi
Normal file
@ -0,0 +1,413 @@
|
||||
// SPDX-License-Identifier: (GPL-2.0+ OR BSD-3-Clause)
|
||||
/*
|
||||
* Copyright (C) STMicroelectronics 2017 - All Rights Reserved
|
||||
* Author: Ludovic Barre <ludovic.barre@st.com> for STMicroelectronics.
|
||||
*/
|
||||
|
||||
#include "stm32mp15-m4-srm.dtsi"
|
||||
#include "stm32mp15-m4-srm-pinctrl.dtsi"
|
||||
#include <dt-bindings/gpio/gpio.h>
|
||||
#include <dt-bindings/mfd/st,stpmic1.h>
|
||||
|
||||
/ {
|
||||
memory@c0000000 {
|
||||
device_type = "memory";
|
||||
reg = <0xC0000000 0x40000000>;
|
||||
};
|
||||
|
||||
reserved-memory {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <1>;
|
||||
ranges;
|
||||
|
||||
mcuram2: mcuram2@10000000 {
|
||||
compatible = "shared-dma-pool";
|
||||
reg = <0x10000000 0x40000>;
|
||||
no-map;
|
||||
};
|
||||
|
||||
vdev0vring0: vdev0vring0@10040000 {
|
||||
compatible = "shared-dma-pool";
|
||||
reg = <0x10040000 0x1000>;
|
||||
no-map;
|
||||
};
|
||||
|
||||
vdev0vring1: vdev0vring1@10041000 {
|
||||
compatible = "shared-dma-pool";
|
||||
reg = <0x10041000 0x1000>;
|
||||
no-map;
|
||||
};
|
||||
|
||||
vdev0buffer: vdev0buffer@10042000 {
|
||||
compatible = "shared-dma-pool";
|
||||
reg = <0x10042000 0x4000>;
|
||||
no-map;
|
||||
};
|
||||
|
||||
mcuram: mcuram@30000000 {
|
||||
compatible = "shared-dma-pool";
|
||||
reg = <0x30000000 0x40000>;
|
||||
no-map;
|
||||
};
|
||||
|
||||
retram: retram@38000000 {
|
||||
compatible = "shared-dma-pool";
|
||||
reg = <0x38000000 0x10000>;
|
||||
no-map;
|
||||
};
|
||||
};
|
||||
|
||||
aliases {
|
||||
serial0 = &uart4;
|
||||
};
|
||||
|
||||
led {
|
||||
compatible = "gpio-leds";
|
||||
led-blue {
|
||||
label = "heartbeat";
|
||||
gpios = <&gpiod 9 GPIO_ACTIVE_HIGH>;
|
||||
linux,default-trigger = "heartbeat";
|
||||
default-state = "off";
|
||||
};
|
||||
};
|
||||
|
||||
sd_switch: regulator-sd_switch {
|
||||
compatible = "regulator-gpio";
|
||||
regulator-name = "sd_switch";
|
||||
regulator-min-microvolt = <1800000>;
|
||||
regulator-max-microvolt = <2900000>;
|
||||
regulator-type = "voltage";
|
||||
regulator-always-on;
|
||||
|
||||
gpios = <&gpiof 14 GPIO_ACTIVE_HIGH>;
|
||||
gpios-states = <0>;
|
||||
states = <1800000 0x1>,
|
||||
<2900000 0x0>;
|
||||
};
|
||||
|
||||
vin: vin {
|
||||
compatible = "regulator-fixed";
|
||||
regulator-name = "vin";
|
||||
regulator-min-microvolt = <5000000>;
|
||||
regulator-max-microvolt = <5000000>;
|
||||
regulator-always-on;
|
||||
};
|
||||
};
|
||||
|
||||
&adc {
|
||||
/* ANA0, ANA1 are dedicated pins and don't need pinctrl: only in6. */
|
||||
pinctrl-0 = <&adc1_in6_pins_a>;
|
||||
pinctrl-names = "default";
|
||||
vdd-supply = <&vdd>;
|
||||
vdda-supply = <&vdda>;
|
||||
vref-supply = <&vdda>;
|
||||
status = "disabled";
|
||||
adc1: adc@0 {
|
||||
st,adc-channels = <0 1 6>;
|
||||
/* 16.5 ck_cycles sampling time */
|
||||
st,min-sample-time-nsecs = <400>;
|
||||
status = "okay";
|
||||
};
|
||||
};
|
||||
|
||||
&cpu0{
|
||||
cpu-supply = <&vddcore>;
|
||||
};
|
||||
|
||||
&cpu1{
|
||||
cpu-supply = <&vddcore>;
|
||||
};
|
||||
|
||||
&crc1 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&dac {
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&dac_ch1_pins_a &dac_ch2_pins_a>;
|
||||
vref-supply = <&vdda>;
|
||||
status = "disabled";
|
||||
dac1: dac@1 {
|
||||
status = "okay";
|
||||
};
|
||||
dac2: dac@2 {
|
||||
status = "okay";
|
||||
};
|
||||
};
|
||||
|
||||
&dma1 {
|
||||
sram = <&dma_pool>;
|
||||
};
|
||||
|
||||
&dma2 {
|
||||
sram = <&dma_pool>;
|
||||
};
|
||||
|
||||
&dts {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&hash1 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&i2c4 {
|
||||
pinctrl-names = "default", "sleep";
|
||||
pinctrl-0 = <&i2c4_pins_a>;
|
||||
pinctrl-1 = <&i2c4_sleep_pins_a>;
|
||||
i2c-scl-rising-time-ns = <185>;
|
||||
i2c-scl-falling-time-ns = <20>;
|
||||
clock-frequency = <400000>;
|
||||
status = "okay";
|
||||
/* spare dmas for other usage */
|
||||
/delete-property/dmas;
|
||||
/delete-property/dma-names;
|
||||
|
||||
pmic: stpmic@33 {
|
||||
compatible = "st,stpmic1";
|
||||
reg = <0x33>;
|
||||
interrupts-extended = <&exti_pwr 55 IRQ_TYPE_EDGE_FALLING>;
|
||||
interrupt-controller;
|
||||
#interrupt-cells = <2>;
|
||||
status = "okay";
|
||||
regulators {
|
||||
compatible = "st,stpmic1-regulators";
|
||||
buck1-supply = <&vin>;
|
||||
buck2-supply = <&vin>;
|
||||
buck3-supply = <&vin>;
|
||||
buck4-supply = <&vin>;
|
||||
ldo1-supply = <&v3v3>;
|
||||
ldo2-supply = <&v3v3>;
|
||||
ldo3-supply = <&vdd_ddr>;
|
||||
ldo4-supply = <&vin>;
|
||||
ldo5-supply = <&v3v3>;
|
||||
ldo6-supply = <&v3v3>;
|
||||
vref_ddr-supply = <&vin>;
|
||||
boost-supply = <&vin>;
|
||||
pwr_sw1-supply = <&bst_out>;
|
||||
pwr_sw2-supply = <&bst_out>;
|
||||
|
||||
vddcore: buck1 {
|
||||
regulator-name = "vddcore";
|
||||
regulator-min-microvolt = <1200000>;
|
||||
regulator-max-microvolt = <1350000>;
|
||||
regulator-always-on;
|
||||
regulator-initial-mode = <0>;
|
||||
regulator-over-current-protection;
|
||||
};
|
||||
|
||||
vdd_ddr: buck2 {
|
||||
regulator-name = "vdd_ddr";
|
||||
regulator-min-microvolt = <1350000>;
|
||||
regulator-max-microvolt = <1350000>;
|
||||
regulator-always-on;
|
||||
regulator-initial-mode = <0>;
|
||||
regulator-over-current-protection;
|
||||
};
|
||||
|
||||
vdd: buck3 {
|
||||
regulator-name = "vdd";
|
||||
regulator-min-microvolt = <3300000>;
|
||||
regulator-max-microvolt = <3300000>;
|
||||
regulator-always-on;
|
||||
st,mask-reset;
|
||||
regulator-initial-mode = <0>;
|
||||
regulator-over-current-protection;
|
||||
};
|
||||
|
||||
v3v3: buck4 {
|
||||
regulator-name = "v3v3";
|
||||
regulator-min-microvolt = <3300000>;
|
||||
regulator-max-microvolt = <3300000>;
|
||||
regulator-always-on;
|
||||
regulator-over-current-protection;
|
||||
regulator-initial-mode = <0>;
|
||||
};
|
||||
|
||||
vdda: ldo1 {
|
||||
regulator-name = "vdda";
|
||||
regulator-min-microvolt = <2900000>;
|
||||
regulator-max-microvolt = <2900000>;
|
||||
interrupts = <IT_CURLIM_LDO1 0>;
|
||||
};
|
||||
|
||||
v2v8: ldo2 {
|
||||
regulator-name = "v2v8";
|
||||
regulator-min-microvolt = <2800000>;
|
||||
regulator-max-microvolt = <2800000>;
|
||||
interrupts = <IT_CURLIM_LDO2 0>;
|
||||
};
|
||||
|
||||
vtt_ddr: ldo3 {
|
||||
regulator-name = "vtt_ddr";
|
||||
regulator-min-microvolt = <500000>;
|
||||
regulator-max-microvolt = <750000>;
|
||||
regulator-always-on;
|
||||
regulator-over-current-protection;
|
||||
};
|
||||
|
||||
vdd_usb: ldo4 {
|
||||
regulator-name = "vdd_usb";
|
||||
interrupts = <IT_CURLIM_LDO4 0>;
|
||||
};
|
||||
|
||||
vdd_sd: ldo5 {
|
||||
regulator-name = "vdd_sd";
|
||||
regulator-min-microvolt = <2900000>;
|
||||
regulator-max-microvolt = <2900000>;
|
||||
interrupts = <IT_CURLIM_LDO5 0>;
|
||||
regulator-boot-on;
|
||||
};
|
||||
|
||||
v1v8: ldo6 {
|
||||
regulator-name = "v1v8";
|
||||
regulator-min-microvolt = <1800000>;
|
||||
regulator-max-microvolt = <1800000>;
|
||||
interrupts = <IT_CURLIM_LDO6 0>;
|
||||
};
|
||||
|
||||
vref_ddr: vref_ddr {
|
||||
regulator-name = "vref_ddr";
|
||||
regulator-always-on;
|
||||
regulator-over-current-protection;
|
||||
};
|
||||
|
||||
bst_out: boost {
|
||||
regulator-name = "bst_out";
|
||||
interrupts = <IT_OCP_BOOST 0>;
|
||||
};
|
||||
|
||||
vbus_otg: pwr_sw1 {
|
||||
regulator-name = "vbus_otg";
|
||||
interrupts = <IT_OCP_OTG 0>;
|
||||
};
|
||||
|
||||
vbus_sw: pwr_sw2 {
|
||||
regulator-name = "vbus_sw";
|
||||
interrupts = <IT_OCP_SWOUT 0>;
|
||||
regulator-active-discharge = <1>;
|
||||
};
|
||||
};
|
||||
|
||||
onkey {
|
||||
compatible = "st,stpmic1-onkey";
|
||||
interrupts = <IT_PONKEY_F 0>, <IT_PONKEY_R 0>;
|
||||
interrupt-names = "onkey-falling", "onkey-rising";
|
||||
power-off-time-sec = <10>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
watchdog {
|
||||
compatible = "st,stpmic1-wdt";
|
||||
status = "disabled";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&ipcc {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&iwdg2 {
|
||||
timeout-sec = <32>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&m4_rproc {
|
||||
memory-region = <&retram>, <&mcuram>, <&mcuram2>, <&vdev0vring0>,
|
||||
<&vdev0vring1>, <&vdev0buffer>;
|
||||
mboxes = <&ipcc 0>, <&ipcc 1>, <&ipcc 2>;
|
||||
mbox-names = "vq0", "vq1", "shutdown";
|
||||
interrupt-parent = <&exti>;
|
||||
interrupts = <68 1>;
|
||||
wakeup-source;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&pwr_regulators {
|
||||
vdd-supply = <&vdd>;
|
||||
vdd_3v3_usbfs-supply = <&vdd_usb>;
|
||||
};
|
||||
|
||||
&rng1 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&rtc {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&sdmmc1 {
|
||||
pinctrl-names = "default", "opendrain", "sleep";
|
||||
pinctrl-0 = <&sdmmc1_b4_pins_a &sdmmc1_dir_pins_a>;
|
||||
pinctrl-1 = <&sdmmc1_b4_od_pins_a &sdmmc1_dir_pins_a>;
|
||||
pinctrl-2 = <&sdmmc1_b4_sleep_pins_a &sdmmc1_dir_sleep_pins_a>;
|
||||
cd-gpios = <&gpiog 1 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>;
|
||||
disable-wp;
|
||||
st,sig-dir;
|
||||
st,neg-edge;
|
||||
st,use-ckin;
|
||||
bus-width = <4>;
|
||||
vmmc-supply = <&vdd_sd>;
|
||||
vqmmc-supply = <&sd_switch>;
|
||||
sd-uhs-sdr12;
|
||||
sd-uhs-sdr25;
|
||||
sd-uhs-sdr50;
|
||||
sd-uhs-ddr50;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&sdmmc2 {
|
||||
pinctrl-names = "default", "opendrain", "sleep";
|
||||
pinctrl-0 = <&sdmmc2_b4_pins_a &sdmmc2_d47_pins_a>;
|
||||
pinctrl-1 = <&sdmmc2_b4_od_pins_a &sdmmc2_d47_pins_a>;
|
||||
pinctrl-2 = <&sdmmc2_b4_sleep_pins_a &sdmmc2_d47_sleep_pins_a>;
|
||||
non-removable;
|
||||
no-sd;
|
||||
no-sdio;
|
||||
st,neg-edge;
|
||||
bus-width = <8>;
|
||||
vmmc-supply = <&v3v3>;
|
||||
vqmmc-supply = <&vdd>;
|
||||
mmc-ddr-3_3v;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&sram {
|
||||
dma_pool: dma_pool@0 {
|
||||
reg = <0x50000 0x10000>;
|
||||
pool;
|
||||
};
|
||||
};
|
||||
|
||||
&timers6 {
|
||||
status = "okay";
|
||||
/* spare dmas for other usage */
|
||||
/delete-property/dmas;
|
||||
/delete-property/dma-names;
|
||||
timer@5 {
|
||||
status = "okay";
|
||||
};
|
||||
};
|
||||
|
||||
&uart4 {
|
||||
pinctrl-names = "default", "sleep", "idle";
|
||||
pinctrl-0 = <&uart4_pins_a>;
|
||||
pinctrl-1 = <&uart4_sleep_pins_a>;
|
||||
pinctrl-2 = <&uart4_idle_pins_a>;
|
||||
/delete-property/dmas;
|
||||
/delete-property/dma-names;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&usbotg_hs {
|
||||
vbus-supply = <&vbus_otg>;
|
||||
};
|
||||
|
||||
&usbphyc_port0 {
|
||||
phy-supply = <&vdd_usb>;
|
||||
};
|
||||
|
||||
&usbphyc_port1 {
|
||||
phy-supply = <&vdd_usb>;
|
||||
};
|
||||
686
arch/arm/dts/stm32mp15xx-evx.dtsi
Normal file
686
arch/arm/dts/stm32mp15xx-evx.dtsi
Normal file
@ -0,0 +1,686 @@
|
||||
// SPDX-License-Identifier: (GPL-2.0+ OR BSD-3-Clause)
|
||||
/*
|
||||
* Copyright (C) STMicroelectronics 2017 - All Rights Reserved
|
||||
* Author: Ludovic Barre <ludovic.barre@st.com> for STMicroelectronics.
|
||||
*/
|
||||
|
||||
#include <dt-bindings/input/input.h>
|
||||
#include <dt-bindings/soc/stm32-hdp.h>
|
||||
|
||||
/ {
|
||||
aliases {
|
||||
ethernet0 = ðernet0;
|
||||
};
|
||||
|
||||
clocks {
|
||||
clk_ext_camera: clk-ext-camera {
|
||||
#clock-cells = <0>;
|
||||
compatible = "fixed-clock";
|
||||
clock-frequency = <24000000>;
|
||||
};
|
||||
};
|
||||
|
||||
joystick {
|
||||
compatible = "gpio-keys";
|
||||
#size-cells = <0>;
|
||||
pinctrl-0 = <&joystick_pins>;
|
||||
pinctrl-names = "default";
|
||||
button-0 {
|
||||
label = "JoySel";
|
||||
linux,code = <KEY_ENTER>;
|
||||
interrupt-parent = <&stmfx_pinctrl>;
|
||||
interrupts = <0 IRQ_TYPE_EDGE_RISING>;
|
||||
};
|
||||
button-1 {
|
||||
label = "JoyDown";
|
||||
linux,code = <KEY_DOWN>;
|
||||
interrupt-parent = <&stmfx_pinctrl>;
|
||||
interrupts = <1 IRQ_TYPE_EDGE_RISING>;
|
||||
};
|
||||
button-2 {
|
||||
label = "JoyLeft";
|
||||
linux,code = <KEY_LEFT>;
|
||||
interrupt-parent = <&stmfx_pinctrl>;
|
||||
interrupts = <2 IRQ_TYPE_EDGE_RISING>;
|
||||
};
|
||||
button-3 {
|
||||
label = "JoyRight";
|
||||
linux,code = <KEY_RIGHT>;
|
||||
interrupt-parent = <&stmfx_pinctrl>;
|
||||
interrupts = <3 IRQ_TYPE_EDGE_RISING>;
|
||||
};
|
||||
button-4 {
|
||||
label = "JoyUp";
|
||||
linux,code = <KEY_UP>;
|
||||
interrupt-parent = <&stmfx_pinctrl>;
|
||||
interrupts = <4 IRQ_TYPE_EDGE_RISING>;
|
||||
};
|
||||
};
|
||||
|
||||
panel_backlight: panel-backlight {
|
||||
compatible = "gpio-backlight";
|
||||
gpios = <&gpiod 13 GPIO_ACTIVE_LOW>;
|
||||
default-on;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
spdif_out: spdif-out {
|
||||
#sound-dai-cells = <0>;
|
||||
compatible = "linux,spdif-dit";
|
||||
status = "okay";
|
||||
|
||||
spdif_out_port: port {
|
||||
spdif_out_endpoint: endpoint {
|
||||
remote-endpoint = <&sai4a_endpoint>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
spdif_in: spdif-in {
|
||||
#sound-dai-cells = <0>;
|
||||
compatible = "linux,spdif-dir";
|
||||
status = "okay";
|
||||
|
||||
spdif_in_port: port {
|
||||
spdif_in_endpoint: endpoint {
|
||||
remote-endpoint = <&spdifrx_endpoint>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
sound {
|
||||
compatible = "audio-graph-card";
|
||||
label = "STM32MP15-EV";
|
||||
routing =
|
||||
"AIF1CLK" , "MCLK1",
|
||||
"AIF2CLK" , "MCLK1",
|
||||
"IN1LN" , "MICBIAS2",
|
||||
"DMIC2DAT" , "MICBIAS1",
|
||||
"DMIC1DAT" , "MICBIAS1";
|
||||
dais = <&sai2a_port &sai2b_port &sai4a_port &spdifrx_port
|
||||
&dfsdm0_port &dfsdm1_port &dfsdm2_port &dfsdm3_port>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
dmic0: dmic-0 {
|
||||
compatible = "dmic-codec";
|
||||
#sound-dai-cells = <1>;
|
||||
sound-name-prefix = "dmic0";
|
||||
status = "okay";
|
||||
|
||||
port {
|
||||
dmic0_endpoint: endpoint {
|
||||
remote-endpoint = <&dfsdm_endpoint0>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
dmic1: dmic-1 {
|
||||
compatible = "dmic-codec";
|
||||
#sound-dai-cells = <1>;
|
||||
sound-name-prefix = "dmic1";
|
||||
status = "okay";
|
||||
|
||||
port {
|
||||
dmic1_endpoint: endpoint {
|
||||
remote-endpoint = <&dfsdm_endpoint1>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
dmic2: dmic-2 {
|
||||
compatible = "dmic-codec";
|
||||
#sound-dai-cells = <1>;
|
||||
sound-name-prefix = "dmic2";
|
||||
status = "okay";
|
||||
|
||||
port {
|
||||
dmic2_endpoint: endpoint {
|
||||
remote-endpoint = <&dfsdm_endpoint2>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
dmic3: dmic-3 {
|
||||
compatible = "dmic-codec";
|
||||
#sound-dai-cells = <1>;
|
||||
sound-name-prefix = "dmic3";
|
||||
status = "okay";
|
||||
|
||||
port {
|
||||
dmic3_endpoint: endpoint {
|
||||
remote-endpoint = <&dfsdm_endpoint3>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
usb_phy_tuning: usb-phy-tuning {
|
||||
st,hs-dc-level = <2>;
|
||||
st,fs-rftime-tuning;
|
||||
st,hs-rftime-reduction;
|
||||
st,hs-current-trim = <15>;
|
||||
st,hs-impedance-trim = <1>;
|
||||
st,squelch-level = <3>;
|
||||
st,hs-rx-offset = <2>;
|
||||
st,no-lsfs-sc;
|
||||
};
|
||||
};
|
||||
|
||||
&cec {
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&cec_pins_a>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&dcmi {
|
||||
status = "okay";
|
||||
pinctrl-names = "default", "sleep";
|
||||
pinctrl-0 = <&dcmi_pins_a>;
|
||||
pinctrl-1 = <&dcmi_sleep_pins_a>;
|
||||
|
||||
port {
|
||||
dcmi_0: endpoint {
|
||||
remote-endpoint = <&ov5640_0>;
|
||||
bus-type = <5>;
|
||||
bus-width = <8>;
|
||||
hsync-active = <0>;
|
||||
vsync-active = <0>;
|
||||
pclk-sample = <1>;
|
||||
pclk-max-frequency = <77000000>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&dfsdm {
|
||||
pinctrl-names = "default", "sleep";
|
||||
pinctrl-0 = <&dfsdm_clkout_pins_a
|
||||
&dfsdm_data1_pins_a &dfsdm_data3_pins_a>;
|
||||
pinctrl-1 = <&dfsdm_clkout_sleep_pins_a
|
||||
&dfsdm_data1_sleep_pins_a &dfsdm_data3_sleep_pins_a>;
|
||||
spi-max-frequency = <2048000>;
|
||||
|
||||
clocks = <&rcc DFSDM_K>, <&rcc ADFSDM_K>;
|
||||
clock-names = "dfsdm", "audio";
|
||||
status = "okay";
|
||||
|
||||
dfsdm0: filter@0 {
|
||||
compatible = "st,stm32-dfsdm-dmic";
|
||||
st,adc-channels = <3>;
|
||||
st,adc-channel-names = "dmic_u1";
|
||||
st,adc-channel-types = "SPI_R";
|
||||
st,adc-channel-clk-src = "CLKOUT";
|
||||
st,filter-order = <3>;
|
||||
status = "okay";
|
||||
|
||||
asoc_pdm0: dfsdm-dai {
|
||||
compatible = "st,stm32h7-dfsdm-dai";
|
||||
#sound-dai-cells = <0>;
|
||||
io-channels = <&dfsdm0 0>;
|
||||
status = "okay";
|
||||
|
||||
dfsdm0_port: port {
|
||||
dfsdm_endpoint0: endpoint {
|
||||
remote-endpoint = <&dmic0_endpoint>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
dfsdm1: filter@1 {
|
||||
compatible = "st,stm32-dfsdm-dmic";
|
||||
st,adc-channels = <0>;
|
||||
st,adc-channel-names = "dmic_u2";
|
||||
st,adc-channel-types = "SPI_F";
|
||||
st,adc-channel-clk-src = "CLKOUT";
|
||||
st,filter-order = <3>;
|
||||
st,adc-alt-channel = <1>;
|
||||
status = "okay";
|
||||
|
||||
asoc_pdm1: dfsdm-dai {
|
||||
compatible = "st,stm32h7-dfsdm-dai";
|
||||
#sound-dai-cells = <0>;
|
||||
io-channels = <&dfsdm1 0>;
|
||||
status = "okay";
|
||||
|
||||
dfsdm1_port: port {
|
||||
dfsdm_endpoint1: endpoint {
|
||||
remote-endpoint = <&dmic1_endpoint>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
dfsdm2: filter@2 {
|
||||
compatible = "st,stm32-dfsdm-dmic";
|
||||
st,adc-channels = <2>;
|
||||
st,adc-channel-names = "dmic_u3";
|
||||
st,adc-channel-types = "SPI_F";
|
||||
st,adc-channel-clk-src = "CLKOUT";
|
||||
st,adc-alt-channel = <1>;
|
||||
st,filter-order = <3>;
|
||||
status = "okay";
|
||||
|
||||
asoc_pdm2: dfsdm-dai {
|
||||
compatible = "st,stm32h7-dfsdm-dai";
|
||||
#sound-dai-cells = <0>;
|
||||
io-channels = <&dfsdm2 0>;
|
||||
status = "okay";
|
||||
|
||||
dfsdm2_port: port {
|
||||
dfsdm_endpoint2: endpoint {
|
||||
remote-endpoint = <&dmic2_endpoint>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
dfsdm3: filter@3 {
|
||||
compatible = "st,stm32-dfsdm-dmic";
|
||||
st,adc-channels = <1>;
|
||||
st,adc-channel-names = "dmic_u4";
|
||||
st,adc-channel-types = "SPI_R";
|
||||
st,adc-channel-clk-src = "CLKOUT";
|
||||
st,filter-order = <3>;
|
||||
status = "okay";
|
||||
|
||||
asoc_pdm3: dfsdm-dai {
|
||||
compatible = "st,stm32h7-dfsdm-dai";
|
||||
#sound-dai-cells = <0>;
|
||||
io-channels = <&dfsdm3 0>;
|
||||
status = "okay";
|
||||
|
||||
dfsdm3_port: port {
|
||||
dfsdm_endpoint3: endpoint {
|
||||
remote-endpoint = <&dmic3_endpoint>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
ðernet0 {
|
||||
status = "okay";
|
||||
pinctrl-0 = <ðernet0_rgmii_pins_a>;
|
||||
pinctrl-1 = <ðernet0_rgmii_sleep_pins_a>;
|
||||
pinctrl-names = "default", "sleep";
|
||||
phy-mode = "rgmii-id";
|
||||
max-speed = <1000>;
|
||||
phy-handle = <&phy0>;
|
||||
nvmem-cells = <ðernet_mac_address>;
|
||||
nvmem-cell-names = "mac-address";
|
||||
|
||||
mdio0 {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
compatible = "snps,dwmac-mdio";
|
||||
phy0: ethernet-phy@0 {
|
||||
reg = <0>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&fmc {
|
||||
pinctrl-names = "default", "sleep";
|
||||
pinctrl-0 = <&fmc_pins_a>;
|
||||
pinctrl-1 = <&fmc_sleep_pins_a>;
|
||||
status = "okay";
|
||||
|
||||
nand-controller@4,0 {
|
||||
status = "okay";
|
||||
|
||||
nand@0 {
|
||||
reg = <0>;
|
||||
nand-on-flash-bbt;
|
||||
#address-cells = <1>;
|
||||
#size-cells = <1>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&hdp {
|
||||
pinctrl-names = "default", "sleep";
|
||||
pinctrl-0 = <&hdp0_pins_a &hdp6_pins_a &hdp7_pins_a>;
|
||||
pinctrl-1 = <&hdp0_pins_sleep_a &hdp6_pins_sleep_a &hdp7_pins_sleep_a>;
|
||||
status = "disabled";
|
||||
|
||||
muxing-hdp = <(STM32_HDP(0, HDP0_GPOVAL_0) |
|
||||
STM32_HDP(6, HDP6_GPOVAL_6) |
|
||||
STM32_HDP(7, HDP7_GPOVAL_7))>;
|
||||
};
|
||||
|
||||
&i2c2 {
|
||||
pinctrl-names = "default", "sleep";
|
||||
pinctrl-0 = <&i2c2_pins_a>;
|
||||
pinctrl-1 = <&i2c2_sleep_pins_a>;
|
||||
i2c-scl-rising-time-ns = <185>;
|
||||
i2c-scl-falling-time-ns = <20>;
|
||||
status = "okay";
|
||||
/delete-property/dmas;
|
||||
/delete-property/dma-names;
|
||||
|
||||
wm8994: wm8994@1b {
|
||||
compatible = "wlf,wm8994";
|
||||
#sound-dai-cells = <0>;
|
||||
reg = <0x1b>;
|
||||
status = "okay";
|
||||
|
||||
gpio-controller;
|
||||
#gpio-cells = <2>;
|
||||
|
||||
DBVDD-supply = <&vdd>;
|
||||
SPKVDD1-supply = <&vdd>;
|
||||
SPKVDD2-supply = <&vdd>;
|
||||
AVDD2-supply = <&v1v8>;
|
||||
CPVDD-supply = <&v1v8>;
|
||||
|
||||
wlf,ldoena-always-driven;
|
||||
|
||||
clocks = <&sai2a>;
|
||||
clock-names = "MCLK1";
|
||||
|
||||
wlf,gpio-cfg = <0x8101 0xa100 0xa100 0xa100 0xa101 0xa101 0xa100 0xa101 0xa101 0xa101 0xa101>;
|
||||
|
||||
ports {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
wm8994_tx_port: port@0 {
|
||||
reg = <0>;
|
||||
wm8994_tx_endpoint: endpoint {
|
||||
remote-endpoint = <&sai2a_endpoint>;
|
||||
};
|
||||
};
|
||||
|
||||
wm8994_rx_port: port@1 {
|
||||
reg = <1>;
|
||||
wm8994_rx_endpoint: endpoint {
|
||||
remote-endpoint = <&sai2b_endpoint>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
ov5640: camera@3c {
|
||||
compatible = "ovti,ov5640";
|
||||
reg = <0x3c>;
|
||||
clocks = <&clk_ext_camera>;
|
||||
clock-names = "xclk";
|
||||
DOVDD-supply = <&v2v8>;
|
||||
powerdown-gpios = <&stmfx_pinctrl 18 (GPIO_ACTIVE_HIGH | GPIO_PUSH_PULL)>;
|
||||
reset-gpios = <&stmfx_pinctrl 19 (GPIO_ACTIVE_LOW | GPIO_PUSH_PULL)>;
|
||||
rotation = <180>;
|
||||
status = "okay";
|
||||
|
||||
port {
|
||||
ov5640_0: endpoint {
|
||||
remote-endpoint = <&dcmi_0>;
|
||||
bus-width = <8>;
|
||||
data-shift = <2>; /* lines 9:2 are used */
|
||||
hsync-active = <0>;
|
||||
vsync-active = <0>;
|
||||
pclk-sample = <1>;
|
||||
pclk-max-frequency = <77000000>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
stmfx: stmfx@42 {
|
||||
compatible = "st,stmfx-0300";
|
||||
reg = <0x42>;
|
||||
interrupts = <8 IRQ_TYPE_EDGE_RISING>;
|
||||
interrupt-parent = <&gpioi>;
|
||||
vdd-supply = <&v3v3>;
|
||||
|
||||
stmfx_pinctrl: pinctrl {
|
||||
compatible = "st,stmfx-0300-pinctrl";
|
||||
gpio-controller;
|
||||
#gpio-cells = <2>;
|
||||
interrupt-controller;
|
||||
#interrupt-cells = <2>;
|
||||
gpio-ranges = <&stmfx_pinctrl 0 0 24>;
|
||||
|
||||
goodix_pins: goodix {
|
||||
pins = "gpio14";
|
||||
bias-pull-down;
|
||||
};
|
||||
|
||||
joystick_pins: joystick-pins {
|
||||
pins = "gpio0", "gpio1", "gpio2", "gpio3", "gpio4";
|
||||
bias-pull-down;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&i2c4 {
|
||||
pmic: stpmic@33 {
|
||||
regulators {
|
||||
v1v8: ldo6 {
|
||||
regulator-enable-ramp-delay = <300000>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&i2c5 {
|
||||
pinctrl-names = "default", "sleep";
|
||||
pinctrl-0 = <&i2c5_pins_a>;
|
||||
pinctrl-1 = <&i2c5_sleep_pins_a>;
|
||||
i2c-scl-rising-time-ns = <185>;
|
||||
i2c-scl-falling-time-ns = <20>;
|
||||
/delete-property/dmas;
|
||||
/delete-property/dma-names;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&m_can1 {
|
||||
pinctrl-names = "default", "sleep";
|
||||
pinctrl-0 = <&m_can1_pins_a>;
|
||||
pinctrl-1 = <&m_can1_sleep_pins_a>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&qspi {
|
||||
pinctrl-names = "default", "sleep";
|
||||
pinctrl-0 = <&qspi_clk_pins_a &qspi_bk1_pins_a &qspi_bk2_pins_a>;
|
||||
pinctrl-1 = <&qspi_clk_sleep_pins_a &qspi_bk1_sleep_pins_a &qspi_bk2_sleep_pins_a>;
|
||||
reg = <0x58003000 0x1000>, <0x70000000 0x4000000>;
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
status = "okay";
|
||||
|
||||
flash0: mx66l51235l@0 {
|
||||
compatible = "jedec,spi-nor";
|
||||
reg = <0>;
|
||||
spi-rx-bus-width = <4>;
|
||||
spi-max-frequency = <108000000>;
|
||||
#address-cells = <1>;
|
||||
#size-cells = <1>;
|
||||
};
|
||||
|
||||
flash1: mx66l51235l@1 {
|
||||
compatible = "jedec,spi-nor";
|
||||
reg = <1>;
|
||||
spi-rx-bus-width = <4>;
|
||||
spi-max-frequency = <108000000>;
|
||||
#address-cells = <1>;
|
||||
#size-cells = <1>;
|
||||
};
|
||||
};
|
||||
|
||||
&sai2 {
|
||||
clocks = <&rcc SAI2>, <&rcc PLL3_Q>, <&rcc PLL3_R>;
|
||||
pinctrl-names = "default", "sleep";
|
||||
pinctrl-0 = <&sai2a_pins_a>, <&sai2b_pins_a>;
|
||||
pinctrl-1 = <&sai2a_sleep_pins_a>, <&sai2b_sleep_pins_a>;
|
||||
clock-names = "pclk", "x8k", "x11k";
|
||||
status = "okay";
|
||||
|
||||
sai2a: audio-controller@4400b004 {
|
||||
#clock-cells = <0>;
|
||||
dma-names = "tx";
|
||||
status = "okay";
|
||||
|
||||
sai2a_port: port {
|
||||
sai2a_endpoint: endpoint {
|
||||
remote-endpoint = <&wm8994_tx_endpoint>;
|
||||
format = "i2s";
|
||||
mclk-fs = <256>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
sai2b: audio-controller@4400b024 {
|
||||
dma-names = "rx";
|
||||
clocks = <&rcc SAI2_K>, <&sai2a>;
|
||||
clock-names = "sai_ck", "MCLK";
|
||||
status = "okay";
|
||||
|
||||
sai2b_port: port {
|
||||
sai2b_endpoint: endpoint {
|
||||
remote-endpoint = <&wm8994_rx_endpoint>;
|
||||
format = "i2s";
|
||||
mclk-fs = <256>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&sai4 {
|
||||
clocks = <&rcc SAI4>, <&rcc PLL3_Q>, <&rcc PLL3_R>;
|
||||
clock-names = "pclk", "x8k", "x11k";
|
||||
status = "okay";
|
||||
|
||||
sai4a: audio-controller@50027004 {
|
||||
pinctrl-names = "default", "sleep";
|
||||
pinctrl-0 = <&sai4a_pins_a>;
|
||||
pinctrl-1 = <&sai4a_sleep_pins_a>;
|
||||
dma-names = "tx";
|
||||
st,iec60958;
|
||||
status = "okay";
|
||||
|
||||
sai4a_port: port {
|
||||
sai4a_endpoint: endpoint {
|
||||
remote-endpoint = <&spdif_out_endpoint>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&sdmmc3 {
|
||||
pinctrl-names = "default", "opendrain", "sleep";
|
||||
pinctrl-0 = <&sdmmc3_b4_pins_a>;
|
||||
pinctrl-1 = <&sdmmc3_b4_od_pins_a>;
|
||||
pinctrl-2 = <&sdmmc3_b4_sleep_pins_a>;
|
||||
broken-cd;
|
||||
st,neg-edge;
|
||||
bus-width = <4>;
|
||||
vmmc-supply = <&v3v3>;
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
&spdifrx {
|
||||
pinctrl-names = "default", "sleep";
|
||||
pinctrl-0 = <&spdifrx_pins_a>;
|
||||
pinctrl-1 = <&spdifrx_sleep_pins_a>;
|
||||
status = "okay";
|
||||
|
||||
spdifrx_port: port {
|
||||
spdifrx_endpoint: endpoint {
|
||||
remote-endpoint = <&spdif_in_endpoint>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&spi1 {
|
||||
pinctrl-names = "default", "sleep";
|
||||
pinctrl-0 = <&spi1_pins_a>;
|
||||
pinctrl-1 = <&spi1_sleep_pins_a>;
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
&timers2 {
|
||||
/* spare dmas for other usage (un-delete to enable pwm capture) */
|
||||
/delete-property/dmas;
|
||||
/delete-property/dma-names;
|
||||
status = "disabled";
|
||||
pwm {
|
||||
pinctrl-0 = <&pwm2_pins_a>;
|
||||
pinctrl-1 = <&pwm2_sleep_pins_a>;
|
||||
pinctrl-names = "default", "sleep";
|
||||
status = "okay";
|
||||
};
|
||||
timer@1 {
|
||||
status = "okay";
|
||||
};
|
||||
};
|
||||
|
||||
&timers8 {
|
||||
/delete-property/dmas;
|
||||
/delete-property/dma-names;
|
||||
status = "disabled";
|
||||
pwm {
|
||||
pinctrl-0 = <&pwm8_pins_a>;
|
||||
pinctrl-1 = <&pwm8_sleep_pins_a>;
|
||||
pinctrl-names = "default", "sleep";
|
||||
status = "okay";
|
||||
};
|
||||
timer@7 {
|
||||
status = "okay";
|
||||
};
|
||||
};
|
||||
|
||||
&timers12 {
|
||||
/delete-property/dmas;
|
||||
/delete-property/dma-names;
|
||||
status = "disabled";
|
||||
pwm {
|
||||
pinctrl-0 = <&pwm12_pins_a>;
|
||||
pinctrl-1 = <&pwm12_sleep_pins_a>;
|
||||
pinctrl-names = "default", "sleep";
|
||||
status = "okay";
|
||||
};
|
||||
timer@11 {
|
||||
status = "okay";
|
||||
};
|
||||
};
|
||||
|
||||
&usart3 {
|
||||
pinctrl-names = "default", "sleep", "idle";
|
||||
pinctrl-0 = <&usart3_pins_b>;
|
||||
pinctrl-1 = <&usart3_sleep_pins_b>;
|
||||
pinctrl-2 = <&usart3_idle_pins_b>;
|
||||
/*
|
||||
* HW flow control USART3_RTS is optional, and isn't default wired to
|
||||
* the connector. SB23 needs to be soldered in order to use it, and R77
|
||||
* (ETH_CLK) should be removed.
|
||||
*/
|
||||
uart-has-rtscts;
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
&usbh_ehci {
|
||||
phys = <&usbphyc_port0>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&usbotg_hs {
|
||||
pinctrl-0 = <&usbotg_hs_pins_a>;
|
||||
pinctrl-names = "default";
|
||||
phys = <&usbphyc_port1 0>;
|
||||
phy-names = "usb2-phy";
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&usbphyc {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&usbphyc_port0 {
|
||||
st,phy-tuning = <&usb_phy_tuning>;
|
||||
vbus-supply = <&vbus_sw>;
|
||||
};
|
||||
|
||||
&usbphyc_port1 {
|
||||
st,phy-tuning = <&usb_phy_tuning>;
|
||||
};
|
||||
@ -6,7 +6,6 @@
|
||||
#ifndef _ASM_CONFIG_H_
|
||||
#define _ASM_CONFIG_H_
|
||||
|
||||
#define CONFIG_LMB
|
||||
#define CONFIG_SYS_BOOT_RAMDISK_HIGH
|
||||
|
||||
#if defined(CONFIG_ARCH_LS1021A) || \
|
||||
|
||||
@ -458,6 +458,7 @@ static inline void set_dacr(unsigned int val)
|
||||
|
||||
/* options available for data cache on each page */
|
||||
enum dcache_option {
|
||||
INVALID_ENTRY = 0,
|
||||
DCACHE_OFF = TTB_SECT | TTB_SECT_MAIR(0) | TTB_SECT_XN_MASK,
|
||||
DCACHE_WRITETHROUGH = TTB_SECT | TTB_SECT_MAIR(1),
|
||||
DCACHE_WRITEBACK = TTB_SECT | TTB_SECT_MAIR(2),
|
||||
@ -488,6 +489,7 @@ enum dcache_option {
|
||||
* 1 1 1 Outer/Inner Write-Back, Read-Allocate Write-Allocate
|
||||
*/
|
||||
enum dcache_option {
|
||||
INVALID_ENTRY = 0,
|
||||
DCACHE_OFF = TTB_SECT_DOMAIN(0) | TTB_SECT_XN_MASK | TTB_SECT,
|
||||
DCACHE_WRITETHROUGH = DCACHE_OFF | TTB_SECT_C_MASK,
|
||||
DCACHE_WRITEBACK = DCACHE_WRITETHROUGH | TTB_SECT_B_MASK,
|
||||
@ -497,6 +499,7 @@ enum dcache_option {
|
||||
#define TTB_SECT_AP (3 << 10)
|
||||
/* options available for data cache on each page */
|
||||
enum dcache_option {
|
||||
INVALID_ENTRY = 0,
|
||||
DCACHE_OFF = 0x12,
|
||||
DCACHE_WRITETHROUGH = 0x1a,
|
||||
DCACHE_WRITEBACK = 0x1e,
|
||||
|
||||
@ -6,6 +6,7 @@
|
||||
|
||||
#include <common.h>
|
||||
#include <cpu_func.h>
|
||||
#include <lmb.h>
|
||||
#include <log.h>
|
||||
#include <asm/system.h>
|
||||
#include <asm/cache.h>
|
||||
@ -96,27 +97,33 @@ void mmu_set_region_dcache_behaviour_phys(phys_addr_t start, phys_addr_t phys,
|
||||
mmu_page_table_flush(startpt, stoppt);
|
||||
}
|
||||
|
||||
void mmu_set_region_dcache_behaviour(phys_addr_t start, size_t size,
|
||||
enum dcache_option option)
|
||||
{
|
||||
mmu_set_region_dcache_behaviour_phys(start, start, size, option);
|
||||
}
|
||||
|
||||
__weak void dram_bank_mmu_setup(int bank)
|
||||
{
|
||||
struct bd_info *bd = gd->bd;
|
||||
struct lmb lmb;
|
||||
int i;
|
||||
|
||||
/* bd->bi_dram is available only after relocation */
|
||||
if ((gd->flags & GD_FLG_RELOC) == 0)
|
||||
return;
|
||||
|
||||
/*
|
||||
* don't allow cache on reserved memory tagged 'no-map' in DT
|
||||
* => avoid speculative access to "secure" data
|
||||
*/
|
||||
lmb_init_and_reserve(&lmb, bd, (void *)gd->fdt_blob);
|
||||
|
||||
debug("%s: bank: %d\n", __func__, bank);
|
||||
for (i = bd->bi_dram[bank].start >> MMU_SECTION_SHIFT;
|
||||
i < (bd->bi_dram[bank].start >> MMU_SECTION_SHIFT) +
|
||||
(bd->bi_dram[bank].size >> MMU_SECTION_SHIFT);
|
||||
i++)
|
||||
set_section_dcache(i, DCACHE_DEFAULT_OPTION);
|
||||
i++) {
|
||||
if (lmb_is_reserved_flags(&lmb, i << MMU_SECTION_SHIFT,
|
||||
LMB_NOMAP))
|
||||
set_section_dcache(i, INVALID_ENTRY);
|
||||
else
|
||||
set_section_dcache(i, DCACHE_DEFAULT_OPTION);
|
||||
}
|
||||
}
|
||||
|
||||
/* to activate the MMU we need to set up virtual memory: use 1M areas */
|
||||
@ -313,6 +320,12 @@ int dcache_status(void)
|
||||
{
|
||||
return 0; /* always off */
|
||||
}
|
||||
|
||||
void mmu_set_region_dcache_behaviour(phys_addr_t start, size_t size,
|
||||
enum dcache_option option)
|
||||
{
|
||||
}
|
||||
|
||||
#else
|
||||
void dcache_enable(void)
|
||||
{
|
||||
@ -328,4 +341,10 @@ int dcache_status(void)
|
||||
{
|
||||
return (get_cr() & CR_C) != 0;
|
||||
}
|
||||
|
||||
void mmu_set_region_dcache_behaviour(phys_addr_t start, size_t size,
|
||||
enum dcache_option option)
|
||||
{
|
||||
mmu_set_region_dcache_behaviour_phys(start, start, size, option);
|
||||
}
|
||||
#endif
|
||||
|
||||
@ -56,6 +56,13 @@ config STM32MP15x
|
||||
dual core A7 for STM32MP157/3, monocore for STM32MP151
|
||||
target all the STMicroelectronics board with SOC STM32MP1 family
|
||||
|
||||
config STM32MP15x_STM32IMAGE
|
||||
bool "Support STM32 image for generated U-Boot image"
|
||||
depends on STM32MP15x && TFABOOT
|
||||
help
|
||||
Support of STM32 image generation for SOC STM32MP15x
|
||||
for TF-A boot when FIP container is not used
|
||||
|
||||
choice
|
||||
prompt "STM32MP15x board select"
|
||||
optional
|
||||
@ -93,6 +100,19 @@ config SYS_TEXT_BASE
|
||||
config NR_DRAM_BANKS
|
||||
default 1
|
||||
|
||||
config DDR_CACHEABLE_SIZE
|
||||
hex "Size of the DDR marked cacheable in pre-reloc stage"
|
||||
default 0x10000000 if TFABOOT
|
||||
default 0x40000000
|
||||
help
|
||||
Define the size of the DDR marked as cacheable in U-Boot
|
||||
pre-reloc stage.
|
||||
This option can be useful to avoid speculatif access
|
||||
to secured area of DDR used by TF-A or OP-TEE before U-Boot
|
||||
initialization.
|
||||
The areas marked "no-map" in device tree should be located
|
||||
before this limit: STM32_DDR_BASE + DDR_CACHEABLE_SIZE.
|
||||
|
||||
config SYS_MMCSD_RAW_MODE_U_BOOT_PARTITION_MMC2
|
||||
hex "Partition on MMC2 to use to load U-Boot from"
|
||||
depends on SYS_MMCSD_RAW_MODE_U_BOOT_USE_PARTITION
|
||||
@ -108,23 +128,6 @@ config STM32_ETZPC
|
||||
help
|
||||
Say y to enable STM32 Extended TrustZone Protection
|
||||
|
||||
config CMD_STM32PROG
|
||||
bool "command stm32prog for STM32CudeProgrammer"
|
||||
select DFU
|
||||
select DFU_RAM
|
||||
select DFU_VIRT
|
||||
select PARTITION_TYPE_GUID
|
||||
imply CMD_GPT if MMC
|
||||
imply CMD_MTD if MTD
|
||||
imply DFU_MMC if MMC
|
||||
imply DFU_MTD if MTD
|
||||
help
|
||||
activate a specific command stm32prog for STM32MP soc family
|
||||
witch update the device with the tools STM32CubeProgrammer,
|
||||
using UART with STM32 protocol or USB with DFU protocol
|
||||
NB: access to not volatile memory (NOR/NAND/SD/eMMC) is based
|
||||
on U-Boot DFU framework
|
||||
|
||||
config CMD_STM32KEY
|
||||
bool "command stm32key to fuse public key hash"
|
||||
default y
|
||||
@ -164,6 +167,7 @@ config DEBUG_UART_CLOCK
|
||||
default 64000000
|
||||
endif
|
||||
|
||||
source "arch/arm/mach-stm32mp/cmd_stm32prog/Kconfig"
|
||||
source "board/st/stm32mp1/Kconfig"
|
||||
source "board/dhelectronics/dh_stm32mp1/Kconfig"
|
||||
|
||||
|
||||
@ -11,7 +11,7 @@ obj-y += bsec.o
|
||||
ifdef CONFIG_SPL_BUILD
|
||||
obj-y += spl.o
|
||||
else
|
||||
obj-$(CONFIG_CMD_STM32PROG) += cmd_stm32prog/
|
||||
obj-y += cmd_stm32prog/
|
||||
obj-$(CONFIG_CMD_STM32KEY) += cmd_stm32key.o
|
||||
obj-$(CONFIG_ARMV7_PSCI) += psci.o
|
||||
obj-$(CONFIG_TFABOOT) += boot_params.o
|
||||
|
||||
@ -4,6 +4,7 @@
|
||||
*/
|
||||
|
||||
#include <common.h>
|
||||
#include <clk.h>
|
||||
#include <dm.h>
|
||||
#include <log.h>
|
||||
#include <misc.h>
|
||||
@ -486,6 +487,15 @@ static int stm32mp_bsec_probe(struct udevice *dev)
|
||||
{
|
||||
int otp;
|
||||
struct stm32mp_bsec_platdata *plat;
|
||||
struct clk_bulk clk_bulk;
|
||||
int ret;
|
||||
|
||||
ret = clk_get_bulk(dev, &clk_bulk);
|
||||
if (!ret) {
|
||||
ret = clk_enable_bulk(&clk_bulk);
|
||||
if (ret)
|
||||
return ret;
|
||||
}
|
||||
|
||||
/*
|
||||
* update unlocked shadow for OTP cleared by the rom code
|
||||
|
||||
34
arch/arm/mach-stm32mp/cmd_stm32prog/Kconfig
Normal file
34
arch/arm/mach-stm32mp/cmd_stm32prog/Kconfig
Normal file
@ -0,0 +1,34 @@
|
||||
|
||||
config CMD_STM32PROG
|
||||
bool "command stm32prog for STM32CudeProgrammer"
|
||||
select DFU
|
||||
select DFU_RAM
|
||||
select DFU_VIRT
|
||||
select PARTITION_TYPE_GUID
|
||||
imply CMD_GPT if MMC
|
||||
imply CMD_MTD if MTD
|
||||
imply DFU_MMC if MMC
|
||||
imply DFU_MTD if MTD
|
||||
help
|
||||
activate a specific command stm32prog for STM32MP soc family
|
||||
witch update the device with the tools STM32CubeProgrammer
|
||||
NB: access to not volatile memory (NOR/NAND/SD/eMMC) is based
|
||||
on U-Boot DFU framework
|
||||
|
||||
config CMD_STM32PROG_USB
|
||||
bool "support stm32prog over USB"
|
||||
depends on CMD_STM32PROG
|
||||
default y
|
||||
help
|
||||
activate the command "stm32prog usb" for STM32MP soc family
|
||||
witch update the device with the tools STM32CubeProgrammer,
|
||||
using USB with DFU protocol
|
||||
|
||||
config CMD_STM32PROG_SERIAL
|
||||
bool "support stm32prog over UART"
|
||||
depends on CMD_STM32PROG
|
||||
default y
|
||||
help
|
||||
activate the command "stm32prog serial" for STM32MP soc family
|
||||
with the tools STM32CubeProgrammer using U-Boot serial device
|
||||
and UART protocol.
|
||||
@ -3,7 +3,7 @@
|
||||
# Copyright (C) 2020, STMicroelectronics - All Rights Reserved
|
||||
#
|
||||
|
||||
obj-y += cmd_stm32prog.o
|
||||
obj-y += stm32prog.o
|
||||
obj-y += stm32prog_serial.o
|
||||
obj-y += stm32prog_usb.o
|
||||
obj-$(CONFIG_CMD_STM32PROG) += cmd_stm32prog.o
|
||||
obj-$(CONFIG_CMD_STM32PROG) += stm32prog.o
|
||||
obj-$(CONFIG_CMD_STM32PROG_SERIAL) += stm32prog_serial.o
|
||||
obj-$(CONFIG_CMD_STM32PROG_USB) += stm32prog_usb.o
|
||||
|
||||
@ -50,9 +50,9 @@ static int do_stm32prog(struct cmd_tbl *cmdtp, int flag, int argc,
|
||||
if (argc < 3 || argc > 5)
|
||||
return CMD_RET_USAGE;
|
||||
|
||||
if (!strcmp(argv[1], "usb"))
|
||||
if (IS_ENABLED(CONFIG_CMD_STM32PROG_USB) && !strcmp(argv[1], "usb"))
|
||||
link = LINK_USB;
|
||||
else if (!strcmp(argv[1], "serial"))
|
||||
else if (IS_ENABLED(CONFIG_CMD_STM32PROG_SERIAL) && !strcmp(argv[1], "serial"))
|
||||
link = LINK_SERIAL;
|
||||
|
||||
if (link == LINK_UNDEFINED) {
|
||||
@ -73,15 +73,16 @@ static int do_stm32prog(struct cmd_tbl *cmdtp, int flag, int argc,
|
||||
size = simple_strtoul(argv[4], NULL, 16);
|
||||
|
||||
/* check STM32IMAGE presence */
|
||||
if (size == 0 &&
|
||||
!stm32prog_header_check((struct raw_header_s *)addr, &header)) {
|
||||
size = header.image_length + BL_HEADER_SIZE;
|
||||
if (size == 0) {
|
||||
stm32prog_header_check((struct raw_header_s *)addr, &header);
|
||||
if (header.type == HEADER_STM32IMAGE) {
|
||||
size = header.image_length + BL_HEADER_SIZE;
|
||||
|
||||
/* uImage detected in STM32IMAGE, execute the script */
|
||||
if (IMAGE_FORMAT_LEGACY ==
|
||||
genimg_get_format((void *)(addr + BL_HEADER_SIZE)))
|
||||
return image_source_script(addr + BL_HEADER_SIZE,
|
||||
"script@1");
|
||||
/* uImage detected in STM32IMAGE, execute the script */
|
||||
if (IMAGE_FORMAT_LEGACY ==
|
||||
genimg_get_format((void *)(addr + BL_HEADER_SIZE)))
|
||||
return image_source_script(addr + BL_HEADER_SIZE, "script@1");
|
||||
}
|
||||
}
|
||||
|
||||
if (IS_ENABLED(CONFIG_DM_VIDEO))
|
||||
@ -174,6 +175,7 @@ U_BOOT_CMD(stm32prog, 5, 0, do_stm32prog,
|
||||
"<size> = size of flashlayout\n"
|
||||
);
|
||||
|
||||
#ifdef CONFIG_STM32MP15x_STM32IMAGE
|
||||
bool stm32prog_get_tee_partitions(void)
|
||||
{
|
||||
if (stm32prog_data)
|
||||
@ -181,6 +183,7 @@ bool stm32prog_get_tee_partitions(void)
|
||||
|
||||
return false;
|
||||
}
|
||||
#endif
|
||||
|
||||
bool stm32prog_get_fsbl_nor(void)
|
||||
{
|
||||
|
||||
@ -59,8 +59,6 @@ static const efi_guid_t uuid_mmc[3] = {
|
||||
ROOTFS_MMC2_UUID
|
||||
};
|
||||
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
/* order of column in flash layout file */
|
||||
enum stm32prog_col_t {
|
||||
COL_OPTION,
|
||||
@ -72,6 +70,16 @@ enum stm32prog_col_t {
|
||||
COL_NB_STM32
|
||||
};
|
||||
|
||||
#define FIP_TOC_HEADER_NAME 0xAA640001
|
||||
|
||||
struct fip_toc_header {
|
||||
u32 name;
|
||||
u32 serial_number;
|
||||
u64 flags;
|
||||
};
|
||||
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
/* partition handling routines : CONFIG_CMD_MTDPARTS */
|
||||
int mtdparts_init(void);
|
||||
int find_dev_and_part(const char *id, struct mtd_device **dev,
|
||||
@ -87,46 +95,57 @@ char *stm32prog_get_error(struct stm32prog_data *data)
|
||||
return data->error;
|
||||
}
|
||||
|
||||
u8 stm32prog_header_check(struct raw_header_s *raw_header,
|
||||
struct image_header_s *header)
|
||||
static bool stm32prog_is_fip_header(struct fip_toc_header *header)
|
||||
{
|
||||
return (header->name == FIP_TOC_HEADER_NAME) && header->serial_number;
|
||||
}
|
||||
|
||||
void stm32prog_header_check(struct raw_header_s *raw_header,
|
||||
struct image_header_s *header)
|
||||
{
|
||||
unsigned int i;
|
||||
|
||||
header->present = 0;
|
||||
if (!raw_header || !header) {
|
||||
pr_debug("%s:no header data\n", __func__);
|
||||
return;
|
||||
}
|
||||
|
||||
header->type = HEADER_NONE;
|
||||
header->image_checksum = 0x0;
|
||||
header->image_length = 0x0;
|
||||
|
||||
if (!raw_header || !header) {
|
||||
pr_debug("%s:no header data\n", __func__);
|
||||
return -1;
|
||||
if (stm32prog_is_fip_header((struct fip_toc_header *)raw_header)) {
|
||||
header->type = HEADER_FIP;
|
||||
return;
|
||||
}
|
||||
|
||||
if (raw_header->magic_number !=
|
||||
(('S' << 0) | ('T' << 8) | ('M' << 16) | (0x32 << 24))) {
|
||||
pr_debug("%s:invalid magic number : 0x%x\n",
|
||||
__func__, raw_header->magic_number);
|
||||
return -2;
|
||||
return;
|
||||
}
|
||||
/* only header v1.0 supported */
|
||||
if (raw_header->header_version != 0x00010000) {
|
||||
pr_debug("%s:invalid header version : 0x%x\n",
|
||||
__func__, raw_header->header_version);
|
||||
return -3;
|
||||
return;
|
||||
}
|
||||
if (raw_header->reserved1 != 0x0 || raw_header->reserved2) {
|
||||
pr_debug("%s:invalid reserved field\n", __func__);
|
||||
return -4;
|
||||
return;
|
||||
}
|
||||
for (i = 0; i < (sizeof(raw_header->padding) / 4); i++) {
|
||||
if (raw_header->padding[i] != 0) {
|
||||
pr_debug("%s:invalid padding field\n", __func__);
|
||||
return -5;
|
||||
return;
|
||||
}
|
||||
}
|
||||
header->present = 1;
|
||||
header->type = HEADER_STM32IMAGE;
|
||||
header->image_checksum = le32_to_cpu(raw_header->image_checksum);
|
||||
header->image_length = le32_to_cpu(raw_header->image_length);
|
||||
|
||||
return 0;
|
||||
return;
|
||||
}
|
||||
|
||||
static u32 stm32prog_header_checksum(u32 addr, struct image_header_s *header)
|
||||
@ -349,23 +368,24 @@ static int parse_flash_layout(struct stm32prog_data *data,
|
||||
bool end_of_line, eof;
|
||||
char *p, *start, *last, *col;
|
||||
struct stm32prog_part_t *part;
|
||||
struct image_header_s header;
|
||||
int part_list_size;
|
||||
int i;
|
||||
|
||||
data->part_nb = 0;
|
||||
|
||||
/* check if STM32image is detected */
|
||||
if (!stm32prog_header_check((struct raw_header_s *)addr,
|
||||
&data->header)) {
|
||||
stm32prog_header_check((struct raw_header_s *)addr, &header);
|
||||
if (header.type == HEADER_STM32IMAGE) {
|
||||
u32 checksum;
|
||||
|
||||
addr = addr + BL_HEADER_SIZE;
|
||||
size = data->header.image_length;
|
||||
size = header.image_length;
|
||||
|
||||
checksum = stm32prog_header_checksum(addr, &data->header);
|
||||
if (checksum != data->header.image_checksum) {
|
||||
checksum = stm32prog_header_checksum(addr, &header);
|
||||
if (checksum != header.image_checksum) {
|
||||
stm32prog_err("Layout: invalid checksum : 0x%x expected 0x%x",
|
||||
checksum, data->header.image_checksum);
|
||||
checksum, header.image_checksum);
|
||||
return -EIO;
|
||||
}
|
||||
}
|
||||
@ -768,9 +788,8 @@ static int init_device(struct stm32prog_data *data,
|
||||
part_found = true;
|
||||
}
|
||||
|
||||
/* no partition for this device */
|
||||
if (!part_found) {
|
||||
stm32prog_err("%s (0x%x): Invalid partition",
|
||||
part->name, part->id);
|
||||
pr_debug("\n");
|
||||
continue;
|
||||
}
|
||||
@ -804,7 +823,9 @@ static int treat_partition_list(struct stm32prog_data *data)
|
||||
INIT_LIST_HEAD(&data->dev[j].part_list);
|
||||
}
|
||||
|
||||
#ifdef CONFIG_STM32MP15x_STM32IMAGE
|
||||
data->tee_detected = false;
|
||||
#endif
|
||||
data->fsbl_nor_detected = false;
|
||||
for (i = 0; i < data->part_nb; i++) {
|
||||
part = &data->part_array[i];
|
||||
@ -858,10 +879,12 @@ static int treat_partition_list(struct stm32prog_data *data)
|
||||
/* fallthrough */
|
||||
case STM32PROG_NAND:
|
||||
case STM32PROG_SPI_NAND:
|
||||
#ifdef CONFIG_STM32MP15x_STM32IMAGE
|
||||
if (!data->tee_detected &&
|
||||
!strncmp(part->name, "tee", 3))
|
||||
data->tee_detected = true;
|
||||
break;
|
||||
#endif
|
||||
default:
|
||||
break;
|
||||
}
|
||||
@ -1410,7 +1433,7 @@ static int stm32prog_copy_fsbl(struct stm32prog_part_t *part)
|
||||
|
||||
if (part->target != STM32PROG_NAND &&
|
||||
part->target != STM32PROG_SPI_NAND)
|
||||
return -1;
|
||||
return -EINVAL;
|
||||
|
||||
dfu = dfu_get_entity(part->alt_id);
|
||||
|
||||
@ -1420,8 +1443,10 @@ static int stm32prog_copy_fsbl(struct stm32prog_part_t *part)
|
||||
ret = dfu->read_medium(dfu, 0, (void *)&raw_header, &size);
|
||||
if (ret)
|
||||
return ret;
|
||||
if (stm32prog_header_check(&raw_header, &header))
|
||||
return -1;
|
||||
|
||||
stm32prog_header_check(&raw_header, &header);
|
||||
if (header.type != HEADER_STM32IMAGE)
|
||||
return -ENOENT;
|
||||
|
||||
/* read header + payload */
|
||||
size = header.image_length + BL_HEADER_SIZE;
|
||||
@ -1706,7 +1731,6 @@ void stm32prog_clean(struct stm32prog_data *data)
|
||||
free(data->part_array);
|
||||
free(data->otp_part);
|
||||
free(data->buffer);
|
||||
free(data->header_data);
|
||||
}
|
||||
|
||||
/* DFU callback: used after serial and direct DFU USB access */
|
||||
|
||||
@ -37,8 +37,14 @@ enum stm32prog_link_t {
|
||||
LINK_UNDEFINED,
|
||||
};
|
||||
|
||||
enum stm32prog_header_t {
|
||||
HEADER_NONE,
|
||||
HEADER_STM32IMAGE,
|
||||
HEADER_FIP,
|
||||
};
|
||||
|
||||
struct image_header_s {
|
||||
bool present;
|
||||
enum stm32prog_header_t type;
|
||||
u32 image_checksum;
|
||||
u32 image_length;
|
||||
};
|
||||
@ -115,7 +121,9 @@ struct stm32prog_data {
|
||||
struct stm32prog_dev_t dev[STM32PROG_MAX_DEV]; /* array of device */
|
||||
int part_nb; /* nb of partition */
|
||||
struct stm32prog_part_t *part_array; /* array of partition */
|
||||
#ifdef CONFIG_STM32MP15x_STM32IMAGE
|
||||
bool tee_detected;
|
||||
#endif
|
||||
bool fsbl_nor_detected;
|
||||
|
||||
/* command internal information */
|
||||
@ -126,14 +134,9 @@ struct stm32prog_data {
|
||||
u32 *otp_part;
|
||||
u8 pmic_part[PMIC_SIZE];
|
||||
|
||||
/* STM32 header information */
|
||||
struct raw_header_s *header_data;
|
||||
struct image_header_s header;
|
||||
|
||||
/* SERIAL information */
|
||||
u32 cursor;
|
||||
u32 packet_number;
|
||||
u32 checksum;
|
||||
u8 *buffer; /* size = USART_RAM_BUFFER_SIZE*/
|
||||
int dfu_seq;
|
||||
u8 read_phase;
|
||||
@ -160,8 +163,8 @@ int stm32prog_pmic_read(struct stm32prog_data *data, u32 offset,
|
||||
int stm32prog_pmic_start(struct stm32prog_data *data);
|
||||
|
||||
/* generic part*/
|
||||
u8 stm32prog_header_check(struct raw_header_s *raw_header,
|
||||
struct image_header_s *header);
|
||||
void stm32prog_header_check(struct raw_header_s *raw_header,
|
||||
struct image_header_s *header);
|
||||
int stm32prog_dfu_init(struct stm32prog_data *data);
|
||||
void stm32prog_next_phase(struct stm32prog_data *data);
|
||||
void stm32prog_do_reset(struct stm32prog_data *data);
|
||||
@ -177,9 +180,29 @@ char *stm32prog_get_error(struct stm32prog_data *data);
|
||||
|
||||
/* Main function */
|
||||
int stm32prog_init(struct stm32prog_data *data, ulong addr, ulong size);
|
||||
int stm32prog_serial_init(struct stm32prog_data *data, int link_dev);
|
||||
bool stm32prog_serial_loop(struct stm32prog_data *data);
|
||||
bool stm32prog_usb_loop(struct stm32prog_data *data, int dev);
|
||||
void stm32prog_clean(struct stm32prog_data *data);
|
||||
|
||||
#ifdef CONFIG_CMD_STM32PROG_SERIAL
|
||||
int stm32prog_serial_init(struct stm32prog_data *data, int link_dev);
|
||||
bool stm32prog_serial_loop(struct stm32prog_data *data);
|
||||
#else
|
||||
static inline int stm32prog_serial_init(struct stm32prog_data *data, int link_dev)
|
||||
{
|
||||
return -ENOSYS;
|
||||
}
|
||||
static inline bool stm32prog_serial_loop(struct stm32prog_data *data)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifdef CONFIG_CMD_STM32PROG_USB
|
||||
bool stm32prog_usb_loop(struct stm32prog_data *data, int dev);
|
||||
#else
|
||||
static inline bool stm32prog_usb_loop(struct stm32prog_data *data, int dev)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
@ -59,6 +59,9 @@ const u8 cmd_id[] = {
|
||||
|
||||
#define NB_CMD sizeof(cmd_id)
|
||||
|
||||
/* with 115200 bauds, 20 ms allow to receive the 256 bytes buffer */
|
||||
#define TIMEOUT_SERIAL_BUFFER 30
|
||||
|
||||
/* DFU support for serial *********************************************/
|
||||
static struct dfu_entity *stm32prog_get_entity(struct stm32prog_data *data)
|
||||
{
|
||||
@ -186,36 +189,19 @@ static int stm32prog_read(struct stm32prog_data *data, u8 phase, u32 offset,
|
||||
int stm32prog_serial_init(struct stm32prog_data *data, int link_dev)
|
||||
{
|
||||
struct udevice *dev = NULL;
|
||||
int node;
|
||||
char alias[10];
|
||||
const char *path;
|
||||
struct dm_serial_ops *ops;
|
||||
/* no parity, 8 bits, 1 stop */
|
||||
u32 serial_config = SERIAL_DEFAULT_CONFIG;
|
||||
|
||||
down_serial_dev = NULL;
|
||||
|
||||
sprintf(alias, "serial%d", link_dev);
|
||||
path = fdt_get_alias(gd->fdt_blob, alias);
|
||||
if (!path) {
|
||||
pr_err("%s alias not found", alias);
|
||||
return -ENODEV;
|
||||
}
|
||||
node = fdt_path_offset(gd->fdt_blob, path);
|
||||
if (!uclass_get_device_by_of_offset(UCLASS_SERIAL, node,
|
||||
&dev)) {
|
||||
down_serial_dev = dev;
|
||||
} else if (node > 0 &&
|
||||
!lists_bind_fdt(gd->dm_root, offset_to_ofnode(node),
|
||||
&dev, false)) {
|
||||
if (!device_probe(dev))
|
||||
down_serial_dev = dev;
|
||||
}
|
||||
if (!down_serial_dev) {
|
||||
pr_err("%s = %s device not found", alias, path);
|
||||
if (uclass_get_device_by_seq(UCLASS_SERIAL, link_dev, &dev)) {
|
||||
pr_err("serial %d device not found\n", link_dev);
|
||||
return -ENODEV;
|
||||
}
|
||||
|
||||
down_serial_dev = dev;
|
||||
|
||||
/* force silent console on uart only when used */
|
||||
if (gd->cur_serial_dev == down_serial_dev)
|
||||
gd->flags |= GD_FLG_DISABLE_CONSOLE | GD_FLG_SILENT;
|
||||
@ -225,11 +211,11 @@ int stm32prog_serial_init(struct stm32prog_data *data, int link_dev)
|
||||
ops = serial_get_ops(down_serial_dev);
|
||||
|
||||
if (!ops) {
|
||||
pr_err("%s = %s missing ops", alias, path);
|
||||
pr_err("serial %d = %s missing ops\n", link_dev, dev->name);
|
||||
return -ENODEV;
|
||||
}
|
||||
if (!ops->setconfig) {
|
||||
pr_err("%s = %s missing setconfig", alias, path);
|
||||
pr_err("serial %d = %s missing setconfig\n", link_dev, dev->name);
|
||||
return -ENODEV;
|
||||
}
|
||||
|
||||
@ -280,6 +266,7 @@ static bool stm32prog_serial_get_buffer(u8 *buffer, u32 *count)
|
||||
{
|
||||
struct dm_serial_ops *ops = serial_get_ops(down_serial_dev);
|
||||
int err;
|
||||
ulong start = get_timer(0);
|
||||
|
||||
do {
|
||||
err = ops->getc(down_serial_dev);
|
||||
@ -289,6 +276,10 @@ static bool stm32prog_serial_get_buffer(u8 *buffer, u32 *count)
|
||||
} else if (err == -EAGAIN) {
|
||||
ctrlc();
|
||||
WATCHDOG_RESET();
|
||||
if (get_timer(start) > TIMEOUT_SERIAL_BUFFER) {
|
||||
err = -ETIMEDOUT;
|
||||
break;
|
||||
}
|
||||
} else {
|
||||
break;
|
||||
}
|
||||
@ -308,57 +299,6 @@ static void stm32prog_serial_putc(u8 w_byte)
|
||||
}
|
||||
|
||||
/* Helper function ************************************************/
|
||||
|
||||
static u8 stm32prog_header(struct stm32prog_data *data)
|
||||
{
|
||||
u8 ret;
|
||||
u8 boot = 0;
|
||||
struct dfu_entity *dfu_entity;
|
||||
u64 size = 0;
|
||||
|
||||
dfu_entity = stm32prog_get_entity(data);
|
||||
if (!dfu_entity)
|
||||
return -ENODEV;
|
||||
|
||||
printf("\nSTM32 download write %s\n", dfu_entity->name);
|
||||
|
||||
/* force cleanup to avoid issue with previous read */
|
||||
dfu_transaction_cleanup(dfu_entity);
|
||||
|
||||
ret = stm32prog_header_check(data->header_data,
|
||||
&data->header);
|
||||
|
||||
/* no header : max size is partition size */
|
||||
if (ret) {
|
||||
dfu_entity->get_medium_size(dfu_entity, &size);
|
||||
data->header.image_length = size;
|
||||
}
|
||||
|
||||
/**** Flash the header if necessary for boot partition */
|
||||
if (data->phase < PHASE_FIRST_USER)
|
||||
boot = 1;
|
||||
|
||||
/* write header if boot partition */
|
||||
if (boot) {
|
||||
if (ret) {
|
||||
stm32prog_err("invalid header (error %d)", ret);
|
||||
} else {
|
||||
ret = stm32prog_write(data,
|
||||
(u8 *)data->header_data,
|
||||
BL_HEADER_SIZE);
|
||||
}
|
||||
} else {
|
||||
if (ret)
|
||||
printf(" partition without checksum\n");
|
||||
ret = 0;
|
||||
}
|
||||
|
||||
free(data->header_data);
|
||||
data->header_data = NULL;
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
static u8 stm32prog_start(struct stm32prog_data *data, u32 address)
|
||||
{
|
||||
u8 ret = 0;
|
||||
@ -397,32 +337,14 @@ static u8 stm32prog_start(struct stm32prog_data *data, u32 address)
|
||||
if (!dfu_entity)
|
||||
return -ENODEV;
|
||||
|
||||
if (data->dfu_seq) {
|
||||
ret = dfu_flush(dfu_entity, NULL, 0, data->dfu_seq);
|
||||
data->dfu_seq = 0;
|
||||
if (ret) {
|
||||
stm32prog_err("DFU flush failed [%d]", ret);
|
||||
return ret;
|
||||
}
|
||||
ret = dfu_flush(dfu_entity, NULL, 0, data->dfu_seq);
|
||||
if (ret) {
|
||||
stm32prog_err("DFU flush failed [%d]", ret);
|
||||
return ret;
|
||||
}
|
||||
data->dfu_seq = 0;
|
||||
|
||||
printf("\n received length = 0x%x\n", data->cursor);
|
||||
if (data->header.present) {
|
||||
if (data->cursor !=
|
||||
(data->header.image_length + BL_HEADER_SIZE)) {
|
||||
stm32prog_err("transmission interrupted (length=0x%x expected=0x%x)",
|
||||
data->cursor,
|
||||
data->header.image_length +
|
||||
BL_HEADER_SIZE);
|
||||
return -EIO;
|
||||
}
|
||||
if (data->header.image_checksum != data->checksum) {
|
||||
stm32prog_err("invalid checksum received (0x%x expected 0x%x)",
|
||||
data->checksum,
|
||||
data->header.image_checksum);
|
||||
return -EIO;
|
||||
}
|
||||
printf("\n checksum OK (0x%x)\n", data->checksum);
|
||||
}
|
||||
|
||||
/* update DFU with received flashlayout */
|
||||
if (data->phase == PHASE_FLASHLAYOUT)
|
||||
@ -645,14 +567,12 @@ static void download_command(struct stm32prog_data *data)
|
||||
u32 counter = 0x0, codesize = 0x0;
|
||||
u8 *ramaddress = 0;
|
||||
u8 rcv_data = 0x0;
|
||||
struct image_header_s *image_header = &data->header;
|
||||
u32 cursor = data->cursor;
|
||||
long size = 0;
|
||||
u8 operation;
|
||||
u32 packet_number;
|
||||
u32 result = ACK_BYTE;
|
||||
u8 ret;
|
||||
unsigned int i;
|
||||
bool error;
|
||||
int rcv;
|
||||
|
||||
@ -686,13 +606,8 @@ static void download_command(struct stm32prog_data *data)
|
||||
if (packet_number == 0) {
|
||||
/* erase: re-initialize the image_header struct */
|
||||
data->packet_number = 0;
|
||||
if (data->header_data)
|
||||
memset(data->header_data, 0, BL_HEADER_SIZE);
|
||||
else
|
||||
data->header_data = calloc(1, BL_HEADER_SIZE);
|
||||
cursor = 0;
|
||||
data->cursor = 0;
|
||||
data->checksum = 0;
|
||||
/*idx = cursor;*/
|
||||
} else {
|
||||
data->packet_number++;
|
||||
@ -740,7 +655,7 @@ static void download_command(struct stm32prog_data *data)
|
||||
printf("transmission error on packet %d, byte %d\n",
|
||||
packet_number, codesize - counter);
|
||||
/* waiting end of packet before flush & NACK */
|
||||
mdelay(30);
|
||||
mdelay(TIMEOUT_SERIAL_BUFFER);
|
||||
data->packet_number--;
|
||||
result = NACK_BYTE;
|
||||
goto end;
|
||||
@ -758,80 +673,33 @@ static void download_command(struct stm32prog_data *data)
|
||||
/* wait to be sure that all data are received
|
||||
* in the FIFO before flush
|
||||
*/
|
||||
mdelay(30);
|
||||
mdelay(TIMEOUT_SERIAL_BUFFER);
|
||||
data->packet_number--;
|
||||
result = NACK_BYTE;
|
||||
goto end;
|
||||
}
|
||||
|
||||
/* Update current position in buffer */
|
||||
data->cursor += codesize;
|
||||
switch (operation) {
|
||||
case PHASE_OTP:
|
||||
size = codesize;
|
||||
ret = stm32prog_otp_write(data, cursor, data->buffer, &size);
|
||||
break;
|
||||
|
||||
if (operation == PHASE_OTP) {
|
||||
size = data->cursor - cursor;
|
||||
/* no header for OTP */
|
||||
if (stm32prog_otp_write(data, cursor,
|
||||
data->buffer, &size))
|
||||
result = ABORT_BYTE;
|
||||
goto end;
|
||||
case PHASE_PMIC:
|
||||
size = codesize;
|
||||
ret = stm32prog_pmic_write(data, cursor, data->buffer, &size);
|
||||
break;
|
||||
|
||||
default:
|
||||
ret = stm32prog_write(data, data->buffer, codesize);
|
||||
break;
|
||||
}
|
||||
|
||||
if (operation == PHASE_PMIC) {
|
||||
size = data->cursor - cursor;
|
||||
/* no header for PMIC */
|
||||
if (stm32prog_pmic_write(data, cursor,
|
||||
data->buffer, &size))
|
||||
result = ABORT_BYTE;
|
||||
goto end;
|
||||
}
|
||||
|
||||
if (cursor < BL_HEADER_SIZE) {
|
||||
/* size = portion of header in this chunck */
|
||||
if (data->cursor >= BL_HEADER_SIZE)
|
||||
size = BL_HEADER_SIZE - cursor;
|
||||
else
|
||||
size = data->cursor - cursor;
|
||||
memcpy((void *)((u32)(data->header_data) + cursor),
|
||||
data->buffer, size);
|
||||
cursor += size;
|
||||
|
||||
if (cursor == BL_HEADER_SIZE) {
|
||||
/* Check and Write the header */
|
||||
if (stm32prog_header(data)) {
|
||||
result = ABORT_BYTE;
|
||||
goto end;
|
||||
}
|
||||
} else {
|
||||
goto end;
|
||||
}
|
||||
}
|
||||
|
||||
if (image_header->present) {
|
||||
if (data->cursor <= BL_HEADER_SIZE)
|
||||
goto end;
|
||||
/* compute checksum on payload */
|
||||
for (i = (unsigned long)size; i < codesize; i++)
|
||||
data->checksum += data->buffer[i];
|
||||
|
||||
if (data->cursor >
|
||||
image_header->image_length + BL_HEADER_SIZE) {
|
||||
pr_err("expected size exceeded\n");
|
||||
result = ABORT_BYTE;
|
||||
goto end;
|
||||
}
|
||||
|
||||
/* write data (payload) */
|
||||
ret = stm32prog_write(data,
|
||||
&data->buffer[size],
|
||||
codesize - size);
|
||||
} else {
|
||||
/* write all */
|
||||
ret = stm32prog_write(data,
|
||||
data->buffer,
|
||||
codesize);
|
||||
}
|
||||
if (ret)
|
||||
result = ABORT_BYTE;
|
||||
else
|
||||
/* Update current position in buffer */
|
||||
data->cursor += codesize;
|
||||
|
||||
end:
|
||||
stm32prog_serial_result(result);
|
||||
|
||||
@ -4,7 +4,7 @@
|
||||
#
|
||||
|
||||
ifndef CONFIG_SPL
|
||||
INPUTS-y += u-boot.stm32
|
||||
INPUTS-$(CONFIG_STM32MP15x_STM32IMAGE) += u-boot.stm32
|
||||
else
|
||||
ifdef CONFIG_SPL_BUILD
|
||||
INPUTS-y += u-boot-spl.stm32
|
||||
|
||||
@ -219,18 +219,21 @@ static void early_enable_caches(void)
|
||||
if (CONFIG_IS_ENABLED(SYS_DCACHE_OFF))
|
||||
return;
|
||||
|
||||
#if !(CONFIG_IS_ENABLED(SYS_ICACHE_OFF) && CONFIG_IS_ENABLED(SYS_DCACHE_OFF))
|
||||
gd->arch.tlb_size = PGTABLE_SIZE;
|
||||
gd->arch.tlb_addr = (unsigned long)&early_tlb;
|
||||
#endif
|
||||
|
||||
dcache_enable();
|
||||
|
||||
if (IS_ENABLED(CONFIG_SPL_BUILD))
|
||||
mmu_set_region_dcache_behaviour(
|
||||
ALIGN(STM32_SYSRAM_BASE, MMU_SECTION_SIZE),
|
||||
round_up(STM32_SYSRAM_SIZE, MMU_SECTION_SIZE),
|
||||
ALIGN_DOWN(STM32_SYSRAM_BASE, MMU_SECTION_SIZE),
|
||||
ALIGN(STM32_SYSRAM_SIZE, MMU_SECTION_SIZE),
|
||||
DCACHE_DEFAULT_OPTION);
|
||||
else
|
||||
mmu_set_region_dcache_behaviour(STM32_DDR_BASE, STM32_DDR_SIZE,
|
||||
mmu_set_region_dcache_behaviour(STM32_DDR_BASE,
|
||||
CONFIG_DDR_CACHEABLE_SIZE,
|
||||
DCACHE_DEFAULT_OPTION);
|
||||
}
|
||||
|
||||
@ -260,7 +263,8 @@ int arch_cpu_init(void)
|
||||
|
||||
boot_mode = get_bootmode();
|
||||
|
||||
if ((boot_mode & TAMP_BOOT_DEVICE_MASK) == BOOT_SERIAL_UART)
|
||||
if (IS_ENABLED(CONFIG_CMD_STM32PROG_SERIAL) &&
|
||||
(boot_mode & TAMP_BOOT_DEVICE_MASK) == BOOT_SERIAL_UART)
|
||||
gd->flags |= GD_FLG_SILENT | GD_FLG_DISABLE_CONSOLE;
|
||||
#if defined(CONFIG_DEBUG_UART) && \
|
||||
!defined(CONFIG_TFABOOT) && \
|
||||
@ -460,7 +464,6 @@ static void setup_boot_mode(void)
|
||||
unsigned int instance = (boot_mode & TAMP_BOOT_INSTANCE_MASK) - 1;
|
||||
u32 forced_mode = (boot_ctx & TAMP_BOOT_FORCED_MASK);
|
||||
struct udevice *dev;
|
||||
int alias;
|
||||
|
||||
pr_debug("%s: boot_ctx=0x%x => boot_mode=%x, instance=%d forced=%x\n",
|
||||
__func__, boot_ctx, boot_mode, instance, forced_mode);
|
||||
@ -470,17 +473,22 @@ static void setup_boot_mode(void)
|
||||
break;
|
||||
/* serial : search associated alias in devicetree */
|
||||
sprintf(cmd, "serial@%x", serial_addr[instance]);
|
||||
if (uclass_get_device_by_name(UCLASS_SERIAL, cmd, &dev))
|
||||
if (uclass_get_device_by_name(UCLASS_SERIAL, cmd, &dev)) {
|
||||
/* restore console on error */
|
||||
if (IS_ENABLED(CONFIG_CMD_STM32PROG_SERIAL))
|
||||
gd->flags &= ~(GD_FLG_SILENT |
|
||||
GD_FLG_DISABLE_CONSOLE);
|
||||
printf("uart%d = %s not found in device tree!\n",
|
||||
instance, cmd);
|
||||
break;
|
||||
if (fdtdec_get_alias_seq(gd->fdt_blob, "serial",
|
||||
dev_of_offset(dev), &alias))
|
||||
break;
|
||||
sprintf(cmd, "%d", alias);
|
||||
}
|
||||
sprintf(cmd, "%d", dev->seq);
|
||||
env_set("boot_device", "serial");
|
||||
env_set("boot_instance", cmd);
|
||||
|
||||
/* restore console on uart when not used */
|
||||
if (gd->cur_serial_dev != dev) {
|
||||
if (IS_ENABLED(CONFIG_CMD_STM32PROG_SERIAL) &&
|
||||
(gd->cur_serial_dev != dev)) {
|
||||
gd->flags &= ~(GD_FLG_SILENT |
|
||||
GD_FLG_DISABLE_CONSOLE);
|
||||
printf("serial boot with console enabled!\n");
|
||||
|
||||
@ -328,7 +328,16 @@ int ft_system_setup(void *blob, struct bd_info *bd)
|
||||
"st,package", pkg, false);
|
||||
}
|
||||
|
||||
if (!CONFIG_IS_ENABLED(OPTEE) ||
|
||||
/*
|
||||
* TEMP: remove OP-TEE nodes in kernel device tree
|
||||
* copied from U-Boot device tree by optee_copy_fdt_nodes
|
||||
* when OP-TEE is not detected (probe failed)
|
||||
* these OP-TEE nodes are present in <board>-u-boot.dtsi
|
||||
* under CONFIG_STM32MP15x_STM32IMAGE only for compatibility
|
||||
* when FIP is not used by TF-A
|
||||
*/
|
||||
if (CONFIG_IS_ENABLED(STM32MP15x_STM32IMAGE) &&
|
||||
CONFIG_IS_ENABLED(OPTEE) &&
|
||||
!tee_find_device(NULL, NULL, NULL, NULL))
|
||||
stm32_fdt_disable_optee(blob);
|
||||
|
||||
|
||||
@ -91,8 +91,10 @@ enum boot_device {
|
||||
|
||||
/* TAMP registers */
|
||||
#define TAMP_BACKUP_REGISTER(x) (STM32_TAMP_BASE + 0x100 + 4 * x)
|
||||
/* secure access */
|
||||
#define TAMP_BACKUP_MAGIC_NUMBER TAMP_BACKUP_REGISTER(4)
|
||||
#define TAMP_BACKUP_BRANCH_ADDRESS TAMP_BACKUP_REGISTER(5)
|
||||
/* non secure access */
|
||||
#define TAMP_COPRO_RSC_TBL_ADDRESS TAMP_BACKUP_REGISTER(17)
|
||||
#define TAMP_COPRO_STATE TAMP_BACKUP_REGISTER(18)
|
||||
#define TAMP_BOOT_CONTEXT TAMP_BACKUP_REGISTER(20)
|
||||
|
||||
@ -8,19 +8,53 @@
|
||||
|
||||
#include <linux/arm-smccc.h>
|
||||
|
||||
/* SMC service generic return codes */
|
||||
#define STM32_SMC_OK 0x00000000U
|
||||
#define STM32_SMC_NOT_SUPPORTED 0xFFFFFFFFU
|
||||
#define STM32_SMC_FAILED 0xFFFFFFFEU
|
||||
#define STM32_SMC_INVALID_PARAMS 0xFFFFFFFDU
|
||||
|
||||
/*
|
||||
* SMC function IDs for STM32 Service queries
|
||||
* SMC function IDs for STM32 Service queries.
|
||||
* STM32 SMC services use the space between 0x82000000 and 0x8200FFFF
|
||||
* like this is defined in SMC calling Convention by ARM
|
||||
* for SiP (silicon Partner)
|
||||
* http://infocenter.arm.com/help/topic/com.arm.doc.den0028a/index.html
|
||||
* for SiP (silicon Partner).
|
||||
* https://developer.arm.com/docs/den0028/latest
|
||||
*/
|
||||
#define STM32_SMC_VERSION 0x82000000
|
||||
|
||||
/* Secure Service access from Non-secure */
|
||||
|
||||
/*
|
||||
* SMC function STM32_SMC_PWR.
|
||||
*
|
||||
* Argument a0: (input) SMCC ID.
|
||||
* (output) Status return code.
|
||||
* Argument a1: (input) Service ID (STM32_SMC_REG_xxx).
|
||||
* Argument a2: (input) Register offset or physical address.
|
||||
* (output) Register read value, if applicable.
|
||||
* Argument a3: (input) Register target value if applicable.
|
||||
*/
|
||||
#define STM32_SMC_PWR 0x82001001
|
||||
|
||||
/*
|
||||
* SMC functions STM32_SMC_BSEC.
|
||||
*
|
||||
* Argument a0: (input) SMCC ID.
|
||||
* (output) Status return code.
|
||||
* Argument a1: (input) Service ID (STM32_SMC_READ_xxx/_PROG_xxx/_WRITE_xxx).
|
||||
* (output) OTP read value, if applicable.
|
||||
* Argument a2: (input) OTP index.
|
||||
* Argument a3: (input) OTP value if applicable.
|
||||
*/
|
||||
#define STM32_SMC_BSEC 0x82001003
|
||||
|
||||
/* Service for BSEC */
|
||||
/* Service ID for STM32_SMC_PWR */
|
||||
#define STM32_SMC_REG_READ 0x0
|
||||
#define STM32_SMC_REG_WRITE 0x1
|
||||
#define STM32_SMC_REG_SET 0x2
|
||||
#define STM32_SMC_REG_CLEAR 0x3
|
||||
|
||||
/* Service ID for STM32_SMC_BSEC */
|
||||
#define STM32_SMC_READ_SHADOW 0x01
|
||||
#define STM32_SMC_PROG_OTP 0x02
|
||||
#define STM32_SMC_WRITE_SHADOW 0x03
|
||||
@ -29,12 +63,6 @@
|
||||
#define STM32_SMC_WRITE_ALL 0x06
|
||||
#define STM32_SMC_WRLOCK_OTP 0x07
|
||||
|
||||
/* SMC error codes */
|
||||
#define STM32_SMC_OK 0x0
|
||||
#define STM32_SMC_NOT_SUPPORTED -1
|
||||
#define STM32_SMC_FAILED -2
|
||||
#define STM32_SMC_INVALID_PARAMS -3
|
||||
|
||||
#define stm32_smc_exec(svc, op, data1, data2) \
|
||||
stm32_smc(svc, op, data1, data2, NULL)
|
||||
|
||||
|
||||
@ -11,6 +11,7 @@ int stm32prog_read_medium_virt(struct dfu_entity *dfu, u64 offset,
|
||||
void *buf, long *len);
|
||||
int stm32prog_get_medium_size_virt(struct dfu_entity *dfu, u64 *size);
|
||||
|
||||
/* only needed for CONFIG_STM32MP15x_STM32IMAGE, prototype defined to avoid compilation issue */
|
||||
bool stm32prog_get_tee_partitions(void);
|
||||
|
||||
bool stm32prog_get_fsbl_nor(void);
|
||||
|
||||
@ -8,6 +8,7 @@
|
||||
#include <errno.h>
|
||||
#include <syscon.h>
|
||||
#include <asm/io.h>
|
||||
#include <asm/arch/stm32mp1_smc.h>
|
||||
#include <dm/device_compat.h>
|
||||
#include <linux/bitops.h>
|
||||
#include <linux/err.h>
|
||||
@ -41,6 +42,10 @@ static int stm32mp_pwr_write(struct udevice *dev, uint reg,
|
||||
if (len != 4)
|
||||
return -EINVAL;
|
||||
|
||||
if (IS_ENABLED(CONFIG_TFABOOT))
|
||||
return stm32_smc_exec(STM32_SMC_PWR, STM32_SMC_REG_WRITE,
|
||||
STM32MP_PWR_CR3, val);
|
||||
|
||||
writel(val, priv->base + STM32MP_PWR_CR3);
|
||||
|
||||
return 0;
|
||||
|
||||
@ -55,6 +55,7 @@ u32 spl_mmc_boot_mode(const u32 boot_device)
|
||||
return MMCSD_MODE_RAW;
|
||||
}
|
||||
|
||||
#ifdef CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_USE_PARTITION
|
||||
int spl_mmc_boot_partition(const u32 boot_device)
|
||||
{
|
||||
switch (boot_device) {
|
||||
@ -66,6 +67,7 @@ int spl_mmc_boot_partition(const u32 boot_device)
|
||||
return -EINVAL;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifdef CONFIG_SPL_DISPLAY_PRINT
|
||||
void spl_display_print(void)
|
||||
@ -138,7 +140,8 @@ void board_init_f(ulong dummy)
|
||||
* to avoid speculative access and issue in get_ram_size()
|
||||
*/
|
||||
if (!CONFIG_IS_ENABLED(SYS_DCACHE_OFF))
|
||||
mmu_set_region_dcache_behaviour(STM32_DDR_BASE, STM32_DDR_SIZE,
|
||||
mmu_set_region_dcache_behaviour(STM32_DDR_BASE,
|
||||
CONFIG_DDR_CACHEABLE_SIZE,
|
||||
DCACHE_DEFAULT_OPTION);
|
||||
}
|
||||
|
||||
|
||||
@ -8,7 +8,6 @@
|
||||
|
||||
#define CONFIG_NEEDS_MANUAL_RELOC
|
||||
|
||||
#define CONFIG_LMB
|
||||
#define CONFIG_SYS_BOOT_RAMDISK_HIGH
|
||||
|
||||
#endif
|
||||
|
||||
@ -6,8 +6,6 @@
|
||||
#ifndef _ASM_CONFIG_H_
|
||||
#define _ASM_CONFIG_H_
|
||||
|
||||
#define CONFIG_LMB
|
||||
|
||||
#ifndef CONFIG_SPL_BUILD
|
||||
#define CONFIG_NEEDS_MANUAL_RELOC
|
||||
#endif
|
||||
|
||||
@ -6,7 +6,6 @@
|
||||
#ifndef _ASM_CONFIG_H_
|
||||
#define _ASM_CONFIG_H_
|
||||
|
||||
#define CONFIG_LMB
|
||||
#define CONFIG_SYS_BOOT_RAMDISK_HIGH
|
||||
|
||||
#endif
|
||||
|
||||
@ -7,6 +7,5 @@
|
||||
|
||||
#ifndef _ASM_CONFIG_H_
|
||||
#define _ASM_CONFIG_H_
|
||||
#define CONFIG_LMB
|
||||
|
||||
#endif
|
||||
|
||||
@ -18,7 +18,6 @@
|
||||
#define HWCONFIG_BUFFER_SIZE 256
|
||||
#endif
|
||||
|
||||
#define CONFIG_LMB
|
||||
#define CONFIG_SYS_BOOT_RAMDISK_HIGH
|
||||
|
||||
#ifndef CONFIG_MAX_MEM_MAPPED
|
||||
|
||||
@ -7,7 +7,6 @@
|
||||
#ifndef _ASM_CONFIG_H_
|
||||
#define _ASM_CONFIG_H_
|
||||
|
||||
#define CONFIG_LMB
|
||||
#define CONFIG_SYS_BOOT_RAMDISK_HIGH
|
||||
|
||||
#endif
|
||||
|
||||
@ -75,7 +75,7 @@ int riscv_fdt_copy_resv_mem_node(const void *src, void *dst)
|
||||
pmp_mem.start = addr;
|
||||
pmp_mem.end = addr + size - 1;
|
||||
err = fdtdec_add_reserved_memory(dst, basename, &pmp_mem,
|
||||
&phandle);
|
||||
&phandle, false);
|
||||
if (err < 0 && err != -FDT_ERR_EXISTS) {
|
||||
log_err("failed to add reserved memory: %d\n", err);
|
||||
return err;
|
||||
|
||||
@ -356,6 +356,37 @@
|
||||
sandbox_firmware: sandbox-firmware {
|
||||
compatible = "sandbox,firmware";
|
||||
};
|
||||
|
||||
sandbox-scmi-agent@0 {
|
||||
compatible = "sandbox,scmi-agent";
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
clk_scmi0: protocol@14 {
|
||||
reg = <0x14>;
|
||||
#clock-cells = <1>;
|
||||
};
|
||||
|
||||
reset_scmi0: protocol@16 {
|
||||
reg = <0x16>;
|
||||
#reset-cells = <1>;
|
||||
};
|
||||
};
|
||||
|
||||
sandbox-scmi-agent@1 {
|
||||
compatible = "sandbox,scmi-agent";
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
clk_scmi1: protocol@14 {
|
||||
reg = <0x14>;
|
||||
#clock-cells = <1>;
|
||||
};
|
||||
|
||||
protocol@10 {
|
||||
reg = <0x10>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
pinctrl-gpio {
|
||||
@ -1036,6 +1067,12 @@
|
||||
compatible = "sandbox,virtio2";
|
||||
};
|
||||
|
||||
sandbox_scmi {
|
||||
compatible = "sandbox,scmi-devices";
|
||||
clocks = <&clk_scmi0 7>, <&clk_scmi0 3>, <&clk_scmi1 1>;
|
||||
resets = <&reset_scmi0 3>;
|
||||
};
|
||||
|
||||
pinctrl {
|
||||
compatible = "sandbox,pinctrl";
|
||||
|
||||
|
||||
99
arch/sandbox/include/asm/scmi_test.h
Normal file
99
arch/sandbox/include/asm/scmi_test.h
Normal file
@ -0,0 +1,99 @@
|
||||
/* SPDX-License-Identifier: GPL-2.0 */
|
||||
/*
|
||||
* Copyright (C) 2020, Linaro Limited
|
||||
*/
|
||||
|
||||
#ifndef __SANDBOX_SCMI_TEST_H
|
||||
#define __SANDBOX_SCMI_TEST_H
|
||||
|
||||
struct udevice;
|
||||
struct sandbox_scmi_agent;
|
||||
struct sandbox_scmi_service;
|
||||
|
||||
/**
|
||||
* struct sandbox_scmi_clk - Simulated clock exposed by SCMI
|
||||
* @id: Identifier of the clock used in the SCMI protocol
|
||||
* @enabled: Clock state: true if enabled, false if disabled
|
||||
* @rate: Clock rate in Hertz
|
||||
*/
|
||||
struct sandbox_scmi_clk {
|
||||
uint id;
|
||||
bool enabled;
|
||||
ulong rate;
|
||||
};
|
||||
|
||||
/**
|
||||
* struct sandbox_scmi_reset - Simulated reset controller exposed by SCMI
|
||||
* @asserted: Reset control state: true if asserted, false if desasserted
|
||||
*/
|
||||
struct sandbox_scmi_reset {
|
||||
uint id;
|
||||
bool asserted;
|
||||
};
|
||||
|
||||
/**
|
||||
* struct sandbox_scmi_agent - Simulated SCMI service seen by SCMI agent
|
||||
* @idx: Identifier for the SCMI agent, its index
|
||||
* @clk: Simulated clocks
|
||||
* @clk_count: Simulated clocks array size
|
||||
* @clk: Simulated reset domains
|
||||
* @clk_count: Simulated reset domains array size
|
||||
*/
|
||||
struct sandbox_scmi_agent {
|
||||
uint idx;
|
||||
struct sandbox_scmi_clk *clk;
|
||||
size_t clk_count;
|
||||
struct sandbox_scmi_reset *reset;
|
||||
size_t reset_count;
|
||||
};
|
||||
|
||||
/**
|
||||
* struct sandbox_scmi_service - Reference to simutaed SCMI agents/services
|
||||
* @agent: Pointer to SCMI sandbox agent pointers array
|
||||
* @agent_count: Number of emulated agents exposed in array @agent.
|
||||
*/
|
||||
struct sandbox_scmi_service {
|
||||
struct sandbox_scmi_agent **agent;
|
||||
size_t agent_count;
|
||||
};
|
||||
|
||||
/**
|
||||
* struct sandbox_scmi_devices - Reference to devices probed through SCMI
|
||||
* @clk: Array the clock devices
|
||||
* @clk_count: Number of clock devices probed
|
||||
* @reset: Array the reset controller devices
|
||||
* @reset_count: Number of reset controller devices probed
|
||||
*/
|
||||
struct sandbox_scmi_devices {
|
||||
struct clk *clk;
|
||||
size_t clk_count;
|
||||
struct reset_ctl *reset;
|
||||
size_t reset_count;
|
||||
};
|
||||
|
||||
#ifdef CONFIG_SCMI_FIRMWARE
|
||||
/**
|
||||
* sandbox_scmi_service_context - Get the simulated SCMI services context
|
||||
* @return: Reference to backend simulated resources state
|
||||
*/
|
||||
struct sandbox_scmi_service *sandbox_scmi_service_ctx(void);
|
||||
|
||||
/**
|
||||
* sandbox_scmi_devices_get_ref - Get references to devices accessed through SCMI
|
||||
* @dev: Reference to the test device used get test resources
|
||||
* @return: Reference to the devices probed by the SCMI test
|
||||
*/
|
||||
struct sandbox_scmi_devices *sandbox_scmi_devices_ctx(struct udevice *dev);
|
||||
#else
|
||||
static inline struct sandbox_scmi_service *sandbox_scmi_service_ctx(void)
|
||||
{
|
||||
return NULL;
|
||||
}
|
||||
|
||||
static inline
|
||||
struct sandbox_scmi_devices *sandbox_scmi_devices_ctx(struct udevice *dev)
|
||||
{
|
||||
return NULL;
|
||||
}
|
||||
#endif /* CONFIG_SCMI_FIRMWARE */
|
||||
#endif /* __SANDBOX_SCMI_TEST_H */
|
||||
@ -8,8 +8,6 @@
|
||||
|
||||
#include <asm/processor.h>
|
||||
|
||||
#define CONFIG_LMB
|
||||
|
||||
/* Timer */
|
||||
#define CONFIG_SYS_TIMER_COUNTS_DOWN
|
||||
#define CONFIG_SYS_TIMER_COUNTER (TMU_BASE + 0xc) /* TCNT0 */
|
||||
|
||||
@ -6,7 +6,6 @@
|
||||
#ifndef _ASM_CONFIG_H_
|
||||
#define _ASM_CONFIG_H_
|
||||
|
||||
#define CONFIG_LMB
|
||||
#define CONFIG_SYS_BOOT_RAMDISK_HIGH
|
||||
|
||||
#endif
|
||||
|
||||
@ -9,8 +9,6 @@
|
||||
|
||||
#include <asm/arch/core.h>
|
||||
|
||||
#define CONFIG_LMB
|
||||
|
||||
/*
|
||||
* Make boot parameters available in the MMUv2 virtual memory layout by
|
||||
* restricting used physical memory to the first 128MB.
|
||||
|
||||
@ -8,18 +8,22 @@ config CMD_STBOARD
|
||||
|
||||
config MTDPARTS_NAND0_BOOT
|
||||
string "mtd boot partitions for nand0"
|
||||
default "2m(fsbl),2m(ssbl1),2m(ssbl2)"
|
||||
default "2m(fsbl),2m(ssbl1),2m(ssbl2)" if STM32MP15x_STM32IMAGE || \
|
||||
!TFABOOT
|
||||
default "2m(fsbl),4m(fip1),4m(fip2)"
|
||||
depends on SYS_MTDPARTS_RUNTIME && ARCH_STM32MP
|
||||
help
|
||||
This define the partitions of nand0 used to build mtparts dynamically
|
||||
for boot from nand0.
|
||||
Each partition need to be aligned with the device erase block size,
|
||||
512KB is the max size for the NAND supported by stm32mp1 platform.
|
||||
The fsbl partition support multiple copy of the same binary, one by
|
||||
erase block.
|
||||
|
||||
config MTDPARTS_NAND0_TEE
|
||||
string "mtd tee partitions for nand0"
|
||||
default "512k(teeh),512k(teed),512k(teex)"
|
||||
depends on SYS_MTDPARTS_RUNTIME && ARCH_STM32MP
|
||||
depends on SYS_MTDPARTS_RUNTIME && ARCH_STM32MP && STM32MP15x_STM32IMAGE
|
||||
help
|
||||
This define the tee partitions added in mtparts dynamically
|
||||
when tee is supported with boot from nand0.
|
||||
@ -28,7 +32,9 @@ config MTDPARTS_NAND0_TEE
|
||||
|
||||
config MTDPARTS_NOR0_BOOT
|
||||
string "mtd boot partitions for nor0"
|
||||
default "256k(fsbl1),256k(fsbl2),2m(ssbl),512k(u-boot-env)"
|
||||
default "256k(fsbl1),256k(fsbl2),2m(ssbl),512k(u-boot-env)" if STM32MP15x_STM32IMAGE || \
|
||||
!TFABOOT
|
||||
default "256k(fsbl1),256k(fsbl2),4m(fip),512k(u-boot-env)"
|
||||
depends on SYS_MTDPARTS_RUNTIME && ARCH_STM32MP
|
||||
help
|
||||
This define the partitions of nand0 used to build mtparts dynamically
|
||||
@ -40,24 +46,27 @@ config MTDPARTS_NOR0_BOOT
|
||||
config MTDPARTS_NOR0_TEE
|
||||
string "mtd tee partitions for nor0"
|
||||
default "256k(teeh),512k(teed),256k(teex)"
|
||||
depends on SYS_MTDPARTS_RUNTIME && ARCH_STM32MP
|
||||
depends on SYS_MTDPARTS_RUNTIME && ARCH_STM32MP && STM32MP15x_STM32IMAGE
|
||||
help
|
||||
This define the tee partitions added in mtparts dynamically
|
||||
when tee is supported with boot from nor0.
|
||||
|
||||
config MTDPARTS_SPINAND0_BOOT
|
||||
string "mtd boot partitions for spi-nand0"
|
||||
default "2m(fsbl),2m(ssbl1),2m(ssbl2)"
|
||||
default "2m(fsbl),2m(ssbl1),2m(ssbl2)" if STM32MP15x_STM32IMAGE || !TFABOOT
|
||||
default "2m(fsbl),4m(fip1),4m(fip2)"
|
||||
depends on SYS_MTDPARTS_RUNTIME && ARCH_STM32MP
|
||||
help
|
||||
This define the partitions of nand0 used to build mtparts dynamically
|
||||
for boot from spi-nand0,
|
||||
512KB is the max size for the NAND supported by stm32mp1 platform.
|
||||
The fsbl partition support multiple copy of the same binary, one by
|
||||
erase block.
|
||||
|
||||
config MTDPARTS_SPINAND0_TEE
|
||||
string "mtd tee partitions for spi-nand0"
|
||||
default "512k(teeh),512k(teed),512k(teex)"
|
||||
depends on SYS_MTDPARTS_RUNTIME && ARCH_STM32MP
|
||||
depends on SYS_MTDPARTS_RUNTIME && ARCH_STM32MP && STM32MP15x_STM32IMAGE
|
||||
help
|
||||
This define the tee partitions added in mtparts dynamically
|
||||
when tee is supported with boot from spi-nand0,
|
||||
|
||||
@ -142,7 +142,8 @@ void set_dfu_alt_info(char *interface, char *devstr)
|
||||
board_get_alt_info_mtd(mtd, buf);
|
||||
}
|
||||
|
||||
if (IS_ENABLED(CONFIG_DFU_VIRT)) {
|
||||
if (IS_ENABLED(CONFIG_DFU_VIRT) &&
|
||||
IS_ENABLED(CMD_STM32PROG_USB)) {
|
||||
strncat(buf, "&virt 0=OTP", DFU_ALT_BUF_LEN);
|
||||
|
||||
if (IS_ENABLED(CONFIG_PMIC_STPMIC1))
|
||||
@ -216,7 +217,7 @@ int dfu_read_medium_virt(struct dfu_entity *dfu, u64 offset,
|
||||
return dfu_pmic_read(offset, buf, len);
|
||||
}
|
||||
|
||||
if (CONFIG_IS_ENABLED(CMD_STM32PROG) &&
|
||||
if (IS_ENABLED(CONFIG_CMD_STM32PROG_USB) &&
|
||||
dfu->data.virt.dev_num >= STM32PROG_VIRT_FIRST_DEV_NUM)
|
||||
return stm32prog_read_medium_virt(dfu, offset, buf, len);
|
||||
|
||||
@ -227,7 +228,7 @@ int dfu_read_medium_virt(struct dfu_entity *dfu, u64 offset,
|
||||
int dfu_write_medium_virt(struct dfu_entity *dfu, u64 offset,
|
||||
void *buf, long *len)
|
||||
{
|
||||
if (CONFIG_IS_ENABLED(CMD_STM32PROG) &&
|
||||
if (IS_ENABLED(CONFIG_CMD_STM32PROG_USB) &&
|
||||
dfu->data.virt.dev_num >= STM32PROG_VIRT_FIRST_DEV_NUM)
|
||||
return stm32prog_write_medium_virt(dfu, offset, buf, len);
|
||||
|
||||
@ -236,7 +237,7 @@ int dfu_write_medium_virt(struct dfu_entity *dfu, u64 offset,
|
||||
|
||||
int __weak dfu_get_medium_size_virt(struct dfu_entity *dfu, u64 *size)
|
||||
{
|
||||
if (CONFIG_IS_ENABLED(CMD_STM32PROG) &&
|
||||
if (IS_ENABLED(CONFIG_CMD_STM32PROG_USB) &&
|
||||
dfu->data.virt.dev_num >= STM32PROG_VIRT_FIRST_DEV_NUM)
|
||||
return stm32prog_get_medium_size_virt(dfu, size);
|
||||
|
||||
|
||||
@ -10,7 +10,9 @@
|
||||
#include <env_internal.h>
|
||||
#include <mtd.h>
|
||||
#include <mtd_node.h>
|
||||
#ifdef CONFIG_STM32MP15x_STM32IMAGE
|
||||
#include <tee.h>
|
||||
#endif
|
||||
#include <asm/arch/stm32prog.h>
|
||||
#include <asm/arch/sys_proto.h>
|
||||
|
||||
@ -29,7 +31,9 @@ static void board_set_mtdparts(const char *dev,
|
||||
char *mtdids,
|
||||
char *mtdparts,
|
||||
const char *boot,
|
||||
#ifdef CONFIG_STM32MP15x_STM32IMAGE
|
||||
const char *tee,
|
||||
#endif
|
||||
const char *user)
|
||||
{
|
||||
/* mtdids: "<dev>=<dev>, ...." */
|
||||
@ -53,10 +57,12 @@ static void board_set_mtdparts(const char *dev,
|
||||
strncat(mtdparts, ",", MTDPARTS_LEN);
|
||||
}
|
||||
|
||||
#ifdef CONFIG_STM32MP15x_STM32IMAGE
|
||||
if (tee) {
|
||||
strncat(mtdparts, tee, MTDPARTS_LEN);
|
||||
strncat(mtdparts, ",", MTDPARTS_LEN);
|
||||
}
|
||||
#endif
|
||||
|
||||
strncat(mtdparts, user, MTDPARTS_LEN);
|
||||
}
|
||||
@ -68,7 +74,10 @@ void board_mtdparts_default(const char **mtdids, const char **mtdparts)
|
||||
static char parts[3 * MTDPARTS_LEN + 1];
|
||||
static char ids[MTDIDS_LEN + 1];
|
||||
static bool mtd_initialized;
|
||||
bool tee, nor, nand, spinand, serial;
|
||||
bool nor, nand, spinand, serial;
|
||||
#ifdef CONFIG_STM32MP15x_STM32IMAGE
|
||||
bool tee = false;
|
||||
#endif
|
||||
|
||||
if (mtd_initialized) {
|
||||
*mtdids = ids;
|
||||
@ -76,7 +85,6 @@ void board_mtdparts_default(const char **mtdids, const char **mtdparts)
|
||||
return;
|
||||
}
|
||||
|
||||
tee = false;
|
||||
nor = false;
|
||||
nand = false;
|
||||
spinand = false;
|
||||
@ -87,7 +95,9 @@ void board_mtdparts_default(const char **mtdids, const char **mtdparts)
|
||||
case BOOT_SERIAL_USB:
|
||||
serial = true;
|
||||
if (CONFIG_IS_ENABLED(CMD_STM32PROG)) {
|
||||
#ifdef CONFIG_STM32MP15x_STM32IMAGE
|
||||
tee = stm32prog_get_tee_partitions();
|
||||
#endif
|
||||
nor = stm32prog_get_fsbl_nor();
|
||||
}
|
||||
nand = true;
|
||||
@ -106,9 +116,11 @@ void board_mtdparts_default(const char **mtdids, const char **mtdparts)
|
||||
break;
|
||||
}
|
||||
|
||||
#ifdef CONFIG_STM32MP15x_STM32IMAGE
|
||||
if (!serial && CONFIG_IS_ENABLED(OPTEE) &&
|
||||
tee_find_device(NULL, NULL, NULL, NULL))
|
||||
tee = true;
|
||||
#endif
|
||||
|
||||
memset(parts, 0, sizeof(parts));
|
||||
memset(ids, 0, sizeof(ids));
|
||||
@ -120,29 +132,27 @@ void board_mtdparts_default(const char **mtdids, const char **mtdparts)
|
||||
pr_debug("mtd device = %s\n", dev->name);
|
||||
}
|
||||
|
||||
if (nor || nand) {
|
||||
if (nand) {
|
||||
mtd = get_mtd_device_nm("nand0");
|
||||
if (!IS_ERR_OR_NULL(mtd)) {
|
||||
const char *mtd_boot = CONFIG_MTDPARTS_NAND0_BOOT;
|
||||
const char *mtd_tee = CONFIG_MTDPARTS_NAND0_TEE;
|
||||
|
||||
board_set_mtdparts("nand0", ids, parts,
|
||||
!nor ? mtd_boot : NULL,
|
||||
!nor && tee ? mtd_tee : NULL,
|
||||
CONFIG_MTDPARTS_NAND0_BOOT,
|
||||
#ifdef CONFIG_STM32MP15x_STM32IMAGE
|
||||
!nor && tee ? CONFIG_MTDPARTS_NAND0_TEE : NULL,
|
||||
#endif
|
||||
"-(UBI)");
|
||||
put_mtd_device(mtd);
|
||||
}
|
||||
}
|
||||
|
||||
if (nor || spinand) {
|
||||
if (spinand) {
|
||||
mtd = get_mtd_device_nm("spi-nand0");
|
||||
if (!IS_ERR_OR_NULL(mtd)) {
|
||||
const char *mtd_boot = CONFIG_MTDPARTS_SPINAND0_BOOT;
|
||||
const char *mtd_tee = CONFIG_MTDPARTS_SPINAND0_TEE;
|
||||
|
||||
board_set_mtdparts("spi-nand0", ids, parts,
|
||||
!nor ? mtd_boot : NULL,
|
||||
!nor && tee ? mtd_tee : NULL,
|
||||
CONFIG_MTDPARTS_SPINAND0_BOOT,
|
||||
#ifdef CONFIG_STM32MP15x_STM32IMAGE
|
||||
!nor && tee ? CONFIG_MTDPARTS_SPINAND0_TEE : NULL,
|
||||
#endif
|
||||
"-(UBI)");
|
||||
put_mtd_device(mtd);
|
||||
}
|
||||
@ -150,12 +160,11 @@ void board_mtdparts_default(const char **mtdids, const char **mtdparts)
|
||||
|
||||
if (nor) {
|
||||
if (!uclass_get_device(UCLASS_SPI_FLASH, 0, &dev)) {
|
||||
const char *mtd_boot = CONFIG_MTDPARTS_NOR0_BOOT;
|
||||
const char *mtd_tee = CONFIG_MTDPARTS_NOR0_TEE;
|
||||
|
||||
board_set_mtdparts("nor0", ids, parts,
|
||||
mtd_boot,
|
||||
tee ? mtd_tee : NULL,
|
||||
CONFIG_MTDPARTS_NOR0_BOOT,
|
||||
#ifdef CONFIG_STM32MP15x_STM32IMAGE
|
||||
tee ? CONFIG_MTDPARTS_NOR0_TEE : NULL,
|
||||
#endif
|
||||
"-(nor_user)");
|
||||
}
|
||||
}
|
||||
|
||||
@ -1,6 +1,20 @@
|
||||
/*
|
||||
* Compilation:
|
||||
* mkimage -f fit_copro_kernel_dtb.its fit_copro_kernel_dtb.itb
|
||||
*
|
||||
* M4 firmware to load with remoteproc: rproc-m4-fw.elf
|
||||
*
|
||||
* Files in linux build dir:
|
||||
* - arch/arm/boot/zImage
|
||||
* - arch/arm/boot/dts/stm32mp157c-dk2.dtb
|
||||
* - arch/arm/boot/dts/stm32mp157c-ev1.dtb
|
||||
*
|
||||
* load mmc 0:4 $kernel_addr_r fit_copro_kernel_dtb.itb
|
||||
* bootm $kernel_addr_r
|
||||
* bootm $kernel_addr_r#dk2
|
||||
* bootm $kernel_addr_r#ev1
|
||||
* bootm $kernel_addr_r#dk2-m4
|
||||
* bootm $kernel_addr_r#ev1-m4
|
||||
*/
|
||||
|
||||
/dts-v1/;
|
||||
@ -29,8 +43,8 @@
|
||||
arch = "arm";
|
||||
os = "linux";
|
||||
compression = "none";
|
||||
load = <0xC0008000>;
|
||||
entry = <0xC0008000>;
|
||||
load = <0xC4000000>;
|
||||
entry = <0xC4000000>;
|
||||
hash-1 {
|
||||
algo = "sha1";
|
||||
};
|
||||
|
||||
@ -3,7 +3,7 @@
|
||||
* mkimage -f fit_kernel_dtb.its fit_kernel_dtb.itb
|
||||
*
|
||||
* Files in linux build dir:
|
||||
* - arch/arm/boot/zImage
|
||||
* - arch/arm/boot/Image (gzipped in Image.gz)
|
||||
* - arch/arm/boot/dts/stm32mp157c-dk2.dtb
|
||||
* - arch/arm/boot/dts/stm32mp157c-ev1.dtb
|
||||
*
|
||||
@ -23,11 +23,11 @@
|
||||
images {
|
||||
kernel {
|
||||
description = "Linux kernel";
|
||||
data = /incbin/("zImage");
|
||||
data = /incbin/("Image.gz");
|
||||
type = "kernel";
|
||||
arch = "arm";
|
||||
os = "linux";
|
||||
compression = "none";
|
||||
compression = "gzip";
|
||||
load = <0xC0008000>;
|
||||
entry = <0xC0008000>;
|
||||
hash-1 {
|
||||
|
||||
@ -101,7 +101,9 @@ int checkboard(void)
|
||||
const char *fdt_compat;
|
||||
int fdt_compat_len;
|
||||
|
||||
if (IS_ENABLED(CONFIG_TFABOOT))
|
||||
if (IS_ENABLED(CONFIG_STM32MP15x_STM32IMAGE))
|
||||
mode = "trusted - stm32image";
|
||||
else if (IS_ENABLED(CONFIG_TFABOOT))
|
||||
mode = "trusted";
|
||||
else
|
||||
mode = "basic";
|
||||
@ -288,42 +290,13 @@ static void __maybe_unused led_error_blink(u32 nb_blink)
|
||||
hang();
|
||||
}
|
||||
|
||||
static int board_check_usb_power(void)
|
||||
static int adc_measurement(ofnode node, int adc_count, int *min_uV, int *max_uV)
|
||||
{
|
||||
struct ofnode_phandle_args adc_args;
|
||||
struct udevice *adc;
|
||||
ofnode node;
|
||||
unsigned int raw;
|
||||
int max_uV = 0;
|
||||
int min_uV = USB_START_HIGH_THRESHOLD_UV;
|
||||
int ret, uV, adc_count;
|
||||
u32 nb_blink;
|
||||
u8 i;
|
||||
|
||||
if (!IS_ENABLED(CONFIG_ADC))
|
||||
return -ENODEV;
|
||||
|
||||
node = ofnode_path("/config");
|
||||
if (!ofnode_valid(node)) {
|
||||
debug("%s: no /config node?\n", __func__);
|
||||
return -ENOENT;
|
||||
}
|
||||
|
||||
/*
|
||||
* Retrieve the ADC channels devices and get measurement
|
||||
* for each of them
|
||||
*/
|
||||
adc_count = ofnode_count_phandle_with_args(node, "st,adc_usb_pd",
|
||||
"#io-channel-cells");
|
||||
if (adc_count < 0) {
|
||||
if (adc_count == -ENOENT)
|
||||
return 0;
|
||||
|
||||
pr_err("%s: can't find adc channel (%d)\n", __func__,
|
||||
adc_count);
|
||||
|
||||
return adc_count;
|
||||
}
|
||||
int ret, uV;
|
||||
int i;
|
||||
|
||||
for (i = 0; i < adc_count; i++) {
|
||||
if (ofnode_parse_phandle_with_args(node, "st,adc_usb_pd",
|
||||
@ -352,10 +325,10 @@ static int board_check_usb_power(void)
|
||||
}
|
||||
/* Convert to uV */
|
||||
if (!adc_raw_to_uV(adc, raw, &uV)) {
|
||||
if (uV > max_uV)
|
||||
max_uV = uV;
|
||||
if (uV < min_uV)
|
||||
min_uV = uV;
|
||||
if (uV > *max_uV)
|
||||
*max_uV = uV;
|
||||
if (uV < *min_uV)
|
||||
*min_uV = uV;
|
||||
pr_debug("%s: %s[%02d] = %u, %d uV\n", __func__,
|
||||
adc->name, adc_args.args[0], raw, uV);
|
||||
} else {
|
||||
@ -364,18 +337,66 @@ static int board_check_usb_power(void)
|
||||
}
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int board_check_usb_power(void)
|
||||
{
|
||||
ofnode node;
|
||||
int max_uV = 0;
|
||||
int min_uV = USB_START_HIGH_THRESHOLD_UV;
|
||||
int adc_count, ret;
|
||||
u32 nb_blink;
|
||||
u8 i;
|
||||
|
||||
if (!IS_ENABLED(CONFIG_ADC))
|
||||
return -ENODEV;
|
||||
|
||||
node = ofnode_path("/config");
|
||||
if (!ofnode_valid(node)) {
|
||||
debug("%s: no /config node?\n", __func__);
|
||||
return -ENOENT;
|
||||
}
|
||||
|
||||
/*
|
||||
* If highest value is inside 1.23 Volts and 2.10 Volts, that means
|
||||
* board is plugged on an USB-C 3A power supply and boot process can
|
||||
* continue.
|
||||
* Retrieve the ADC channels devices and get measurement
|
||||
* for each of them
|
||||
*/
|
||||
if (max_uV > USB_START_LOW_THRESHOLD_UV &&
|
||||
max_uV <= USB_START_HIGH_THRESHOLD_UV &&
|
||||
min_uV <= USB_LOW_THRESHOLD_UV)
|
||||
return 0;
|
||||
adc_count = ofnode_count_phandle_with_args(node, "st,adc_usb_pd",
|
||||
"#io-channel-cells");
|
||||
if (adc_count < 0) {
|
||||
if (adc_count == -ENOENT)
|
||||
return 0;
|
||||
|
||||
pr_err("%s: can't find adc channel (%d)\n", __func__,
|
||||
adc_count);
|
||||
|
||||
return adc_count;
|
||||
}
|
||||
|
||||
/* perform maximum of 2 ADC measurement to detect power supply current */
|
||||
for (i = 0; i < 2; i++) {
|
||||
ret = adc_measurement(node, adc_count, &min_uV, &max_uV);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
/*
|
||||
* If highest value is inside 1.23 Volts and 2.10 Volts, that means
|
||||
* board is plugged on an USB-C 3A power supply and boot process can
|
||||
* continue.
|
||||
*/
|
||||
if (max_uV > USB_START_LOW_THRESHOLD_UV &&
|
||||
max_uV <= USB_START_HIGH_THRESHOLD_UV &&
|
||||
min_uV <= USB_LOW_THRESHOLD_UV)
|
||||
return 0;
|
||||
|
||||
if (i == 0) {
|
||||
pr_debug("Previous ADC measurements was not the one expected, retry in 20ms\n");
|
||||
mdelay(20); /* equal to max tPDDebounce duration (min 10ms - max 20ms) */
|
||||
}
|
||||
}
|
||||
|
||||
pr_err("****************************************************\n");
|
||||
|
||||
/*
|
||||
* If highest and lowest value are either both below
|
||||
* USB_LOW_THRESHOLD_UV or both above USB_LOW_THRESHOLD_UV, that
|
||||
@ -583,7 +604,8 @@ error:
|
||||
static bool board_is_dk2(void)
|
||||
{
|
||||
if (CONFIG_IS_ENABLED(TARGET_ST_STM32MP15x) &&
|
||||
of_machine_is_compatible("st,stm32mp157c-dk2"))
|
||||
(of_machine_is_compatible("st,stm32mp157c-dk2") ||
|
||||
of_machine_is_compatible("st,stm32mp157f-dk2")))
|
||||
return true;
|
||||
|
||||
return false;
|
||||
@ -832,10 +854,17 @@ const char *env_ext4_get_dev_part(void)
|
||||
|
||||
return dev_part[(bootmode & TAMP_BOOT_INSTANCE_MASK) - 1];
|
||||
}
|
||||
|
||||
int mmc_get_env_dev(void)
|
||||
{
|
||||
u32 bootmode = get_bootmode();
|
||||
u32 bootmode;
|
||||
|
||||
if (CONFIG_SYS_MMC_ENV_DEV >= 0)
|
||||
return CONFIG_SYS_MMC_ENV_DEV;
|
||||
|
||||
bootmode = get_bootmode();
|
||||
|
||||
/* use boot instance to select the correct mmc device identifier */
|
||||
return (bootmode & TAMP_BOOT_INSTANCE_MASK) - 1;
|
||||
}
|
||||
|
||||
@ -848,9 +877,14 @@ int ft_board_setup(void *blob, struct bd_info *bd)
|
||||
{ "st,stm32mp15-fmc2", MTD_DEV_TYPE_NAND, },
|
||||
{ "st,stm32mp1-fmc2-nfc", MTD_DEV_TYPE_NAND, },
|
||||
};
|
||||
char *boot_device;
|
||||
|
||||
if (IS_ENABLED(CONFIG_FDT_FIXUP_PARTITIONS))
|
||||
fdt_fixup_mtdparts(blob, nodes, ARRAY_SIZE(nodes));
|
||||
/* Check the boot-source and don't update MTD for serial or usb boot */
|
||||
boot_device = env_get("boot_device");
|
||||
if (!boot_device ||
|
||||
(strcmp(boot_device, "serial") && strcmp(boot_device, "usb")))
|
||||
if (IS_ENABLED(CONFIG_FDT_FIXUP_PARTITIONS))
|
||||
fdt_fixup_mtdparts(blob, nodes, ARRAY_SIZE(nodes));
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
@ -416,7 +416,7 @@ config USE_PREBOOT
|
||||
config PREBOOT
|
||||
string "preboot default value"
|
||||
depends on USE_PREBOOT && !USE_DEFAULT_ENV_FILE
|
||||
default "usb start" if USB_KEYBOARD || USB_STORAGE
|
||||
default "usb start" if USB_KEYBOARD
|
||||
default ""
|
||||
help
|
||||
This is the default of "preboot" environment variable.
|
||||
|
||||
@ -15,6 +15,12 @@
|
||||
#include <time.h>
|
||||
#include <watchdog.h>
|
||||
|
||||
#ifdef CONFIG_SPL_BUILD
|
||||
#undef CONFIG_CMDLINE_EDITING
|
||||
#undef CONFIG_AUTO_COMPLETE
|
||||
#undef CONFIG_SHOW_ACTIVITY
|
||||
#endif
|
||||
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
static const char erase_seq[] = "\b \b"; /* erase sequence */
|
||||
|
||||
@ -74,18 +74,20 @@ static const image_header_t *image_get_fdt(ulong fdt_addr)
|
||||
#endif
|
||||
|
||||
static void boot_fdt_reserve_region(struct lmb *lmb, uint64_t addr,
|
||||
uint64_t size)
|
||||
uint64_t size, enum lmb_flags flags)
|
||||
{
|
||||
long ret;
|
||||
|
||||
ret = lmb_reserve(lmb, addr, size);
|
||||
ret = lmb_reserve_flags(lmb, addr, size, flags);
|
||||
if (ret >= 0) {
|
||||
debug(" reserving fdt memory region: addr=%llx size=%llx\n",
|
||||
(unsigned long long)addr, (unsigned long long)size);
|
||||
debug(" reserving fdt memory region: addr=%llx size=%llx flags=%x\n",
|
||||
(unsigned long long)addr,
|
||||
(unsigned long long)size, flags);
|
||||
} else {
|
||||
puts("ERROR: reserving fdt memory region failed ");
|
||||
printf("(addr=%llx size=%llx)\n",
|
||||
(unsigned long long)addr, (unsigned long long)size);
|
||||
printf("(addr=%llx size=%llx flags=%x)\n",
|
||||
(unsigned long long)addr,
|
||||
(unsigned long long)size, flags);
|
||||
}
|
||||
}
|
||||
|
||||
@ -105,6 +107,7 @@ void boot_fdt_add_mem_rsv_regions(struct lmb *lmb, void *fdt_blob)
|
||||
int i, total, ret;
|
||||
int nodeoffset, subnode;
|
||||
struct fdt_resource res;
|
||||
enum lmb_flags flags;
|
||||
|
||||
if (fdt_check_header(fdt_blob) != 0)
|
||||
return;
|
||||
@ -114,7 +117,7 @@ void boot_fdt_add_mem_rsv_regions(struct lmb *lmb, void *fdt_blob)
|
||||
for (i = 0; i < total; i++) {
|
||||
if (fdt_get_mem_rsv(fdt_blob, i, &addr, &size) != 0)
|
||||
continue;
|
||||
boot_fdt_reserve_region(lmb, addr, size);
|
||||
boot_fdt_reserve_region(lmb, addr, size, LMB_NONE);
|
||||
}
|
||||
|
||||
/* process reserved-memory */
|
||||
@ -126,9 +129,13 @@ void boot_fdt_add_mem_rsv_regions(struct lmb *lmb, void *fdt_blob)
|
||||
ret = fdt_get_resource(fdt_blob, subnode, "reg", 0,
|
||||
&res);
|
||||
if (!ret && fdtdec_get_is_enabled(fdt_blob, subnode)) {
|
||||
flags = LMB_NONE;
|
||||
if (fdtdec_get_bool(fdt_blob, subnode,
|
||||
"no-map"))
|
||||
flags = LMB_NOMAP;
|
||||
addr = res.start;
|
||||
size = res.end - res.start + 1;
|
||||
boot_fdt_reserve_region(lmb, addr, size);
|
||||
boot_fdt_reserve_region(lmb, addr, size, flags);
|
||||
}
|
||||
|
||||
subnode = fdt_next_subnode(fdt_blob, subnode);
|
||||
|
||||
@ -122,6 +122,7 @@ CONFIG_BUTTON=y
|
||||
CONFIG_BUTTON_GPIO=y
|
||||
CONFIG_CLK=y
|
||||
CONFIG_CLK_COMPOSITE_CCF=y
|
||||
CONFIG_CLK_SCMI=y
|
||||
CONFIG_SANDBOX_CLK_CCF=y
|
||||
CONFIG_CPU=y
|
||||
CONFIG_DM_DEMO=y
|
||||
@ -132,6 +133,8 @@ CONFIG_BOARD_SANDBOX=y
|
||||
CONFIG_DMA=y
|
||||
CONFIG_DMA_CHANNELS=y
|
||||
CONFIG_SANDBOX_DMA=y
|
||||
CONFIG_FIRMWARE=y
|
||||
CONFIG_SCMI_FIRMWARE=y
|
||||
CONFIG_GPIO_HOG=y
|
||||
CONFIG_DM_GPIO_LOOKUP_LABEL=y
|
||||
CONFIG_PM8916_GPIO=y
|
||||
@ -217,6 +220,7 @@ CONFIG_REMOTEPROC_SANDBOX=y
|
||||
CONFIG_DM_RESET=y
|
||||
CONFIG_SANDBOX_RESET=y
|
||||
CONFIG_RESET_SYSCON=y
|
||||
CONFIG_RESET_SCMI=y
|
||||
CONFIG_DM_RNG=y
|
||||
CONFIG_DM_RTC=y
|
||||
CONFIG_RTC_RV8803=y
|
||||
|
||||
@ -18,6 +18,7 @@ CONFIG_SPL_SPI_SUPPORT=y
|
||||
CONFIG_DEFAULT_DEVICE_TREE="stm32mp157c-ev1"
|
||||
CONFIG_DISTRO_DEFAULTS=y
|
||||
CONFIG_FIT=y
|
||||
CONFIG_BOOTDELAY=1
|
||||
CONFIG_BOOTCOMMAND="run bootcmd_stm32mp"
|
||||
CONFIG_BOARD_EARLY_INIT_F=y
|
||||
CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_USE_PARTITION=y
|
||||
@ -31,8 +32,6 @@ CONFIG_SPL_SPI_FLASH_MTD=y
|
||||
CONFIG_SYS_PROMPT="STM32MP> "
|
||||
CONFIG_CMD_ADTIMG=y
|
||||
# CONFIG_CMD_ELF is not set
|
||||
# CONFIG_CMD_EXPORTENV is not set
|
||||
# CONFIG_CMD_IMPORTENV is not set
|
||||
CONFIG_CMD_ERASEENV=y
|
||||
CONFIG_CMD_MEMINFO=y
|
||||
CONFIG_CMD_MEMTEST=y
|
||||
@ -69,6 +68,7 @@ CONFIG_ENV_UBI_PART="UBI"
|
||||
CONFIG_ENV_UBI_VOLUME="uboot_config"
|
||||
CONFIG_ENV_UBI_VOLUME_REDUND="uboot_config_r"
|
||||
CONFIG_SYS_RELOC_GD_ENV_ADDR=y
|
||||
CONFIG_SYS_MMC_ENV_DEV=-1
|
||||
# CONFIG_SPL_ENV_IS_NOWHERE is not set
|
||||
# CONFIG_SPL_ENV_IS_IN_SPI_FLASH is not set
|
||||
CONFIG_STM32_ADC=y
|
||||
@ -121,6 +121,7 @@ CONFIG_DM_REGULATOR_FIXED=y
|
||||
CONFIG_DM_REGULATOR_GPIO=y
|
||||
CONFIG_DM_REGULATOR_STM32_VREFBUF=y
|
||||
CONFIG_DM_REGULATOR_STPMIC1=y
|
||||
CONFIG_STM32MP1_DDR_INTERACTIVE=y
|
||||
CONFIG_REMOTEPROC_STM32_COPRO=y
|
||||
CONFIG_DM_RNG=y
|
||||
CONFIG_RNG_STM32MP1=y
|
||||
@ -153,3 +154,4 @@ CONFIG_WDT=y
|
||||
CONFIG_WDT_STM32MP=y
|
||||
CONFIG_ERRNO_STR=y
|
||||
CONFIG_FDT_FIXUP_PARTITIONS=y
|
||||
CONFIG_LMB_RESERVED_REGIONS=16
|
||||
|
||||
@ -17,6 +17,7 @@ CONFIG_FIT=y
|
||||
CONFIG_SPL_LOAD_FIT=y
|
||||
CONFIG_SPL_FIT_SOURCE="board/dhelectronics/dh_stm32mp1/u-boot-dhcom.its"
|
||||
# CONFIG_USE_SPL_FIT_GENERATOR is not set
|
||||
CONFIG_BOOTDELAY=1
|
||||
CONFIG_BOOTCOMMAND="run bootcmd_stm32mp"
|
||||
CONFIG_BOARD_EARLY_INIT_F=y
|
||||
CONFIG_SPL_LEGACY_IMAGE_SUPPORT=y
|
||||
|
||||
@ -17,6 +17,7 @@ CONFIG_FIT=y
|
||||
CONFIG_SPL_LOAD_FIT=y
|
||||
CONFIG_SPL_FIT_SOURCE="board/dhelectronics/dh_stm32mp1/u-boot-dhcor.its"
|
||||
# CONFIG_USE_SPL_FIT_GENERATOR is not set
|
||||
CONFIG_BOOTDELAY=1
|
||||
CONFIG_BOOTCOMMAND="run bootcmd_stm32mp"
|
||||
CONFIG_BOARD_EARLY_INIT_F=y
|
||||
CONFIG_SPL_LEGACY_IMAGE_SUPPORT=y
|
||||
|
||||
@ -2,21 +2,20 @@ CONFIG_ARM=y
|
||||
CONFIG_ARCH_STM32MP=y
|
||||
CONFIG_TFABOOT=y
|
||||
CONFIG_SYS_MALLOC_F_LEN=0x3000
|
||||
CONFIG_ENV_OFFSET=0x280000
|
||||
CONFIG_ENV_OFFSET=0x480000
|
||||
CONFIG_ENV_SECT_SIZE=0x40000
|
||||
CONFIG_TARGET_ST_STM32MP15x=y
|
||||
CONFIG_CMD_STM32PROG=y
|
||||
CONFIG_TYPEC_STUSB160X=y
|
||||
CONFIG_ENV_OFFSET_REDUND=0x2C0000
|
||||
CONFIG_ENV_OFFSET_REDUND=0x4C0000
|
||||
CONFIG_DEFAULT_DEVICE_TREE="stm32mp157c-ev1"
|
||||
CONFIG_DISTRO_DEFAULTS=y
|
||||
CONFIG_FIT=y
|
||||
CONFIG_BOOTDELAY=1
|
||||
CONFIG_BOOTCOMMAND="run bootcmd_stm32mp"
|
||||
CONFIG_SYS_PROMPT="STM32MP> "
|
||||
CONFIG_CMD_ADTIMG=y
|
||||
# CONFIG_CMD_ELF is not set
|
||||
# CONFIG_CMD_EXPORTENV is not set
|
||||
# CONFIG_CMD_IMPORTENV is not set
|
||||
CONFIG_CMD_ERASEENV=y
|
||||
CONFIG_CMD_MEMINFO=y
|
||||
CONFIG_CMD_MEMTEST=y
|
||||
@ -51,7 +50,9 @@ CONFIG_ENV_UBI_PART="UBI"
|
||||
CONFIG_ENV_UBI_VOLUME="uboot_config"
|
||||
CONFIG_ENV_UBI_VOLUME_REDUND="uboot_config_r"
|
||||
CONFIG_SYS_RELOC_GD_ENV_ADDR=y
|
||||
CONFIG_SYS_MMC_ENV_DEV=-1
|
||||
CONFIG_STM32_ADC=y
|
||||
CONFIG_CLK_SCMI=y
|
||||
CONFIG_SET_DFU_ALT_INFO=y
|
||||
CONFIG_USB_FUNCTION_FASTBOOT=y
|
||||
CONFIG_FASTBOOT_BUF_ADDR=0xC0000000
|
||||
@ -99,7 +100,9 @@ CONFIG_DM_REGULATOR_FIXED=y
|
||||
CONFIG_DM_REGULATOR_GPIO=y
|
||||
CONFIG_DM_REGULATOR_STM32_VREFBUF=y
|
||||
CONFIG_DM_REGULATOR_STPMIC1=y
|
||||
CONFIG_REMOTEPROC_OPTEE=y
|
||||
CONFIG_REMOTEPROC_STM32_COPRO=y
|
||||
CONFIG_RESET_SCMI=y
|
||||
CONFIG_DM_RNG=y
|
||||
CONFIG_RNG_STM32MP1=y
|
||||
CONFIG_DM_RTC=y
|
||||
@ -134,3 +137,4 @@ CONFIG_WDT=y
|
||||
CONFIG_WDT_STM32MP=y
|
||||
CONFIG_ERRNO_STR=y
|
||||
CONFIG_FDT_FIXUP_PARTITIONS=y
|
||||
CONFIG_LMB_RESERVED_REGIONS=16
|
||||
|
||||
@ -52,15 +52,23 @@ And the necessary drivers
|
||||
Currently the following boards are supported:
|
||||
|
||||
+ stm32mp157a-dk1.dts
|
||||
+ stm32mp157a-ed1.dts
|
||||
+ stm32mp157a-ev1.dts
|
||||
+ stm32mp157c-dk2.dts
|
||||
+ stm32mp157c-ed1.dts
|
||||
+ stm32mp157c-ev1.dts
|
||||
+ stm32mp157d-dk1.dts
|
||||
+ stm32mp157d-ed1.dts
|
||||
+ stm32mp157d-ev1.dts
|
||||
+ stm32mp157f-dk2.dts
|
||||
+ stm32mp157f-ed1.dts
|
||||
+ stm32mp157f-ev1.dts
|
||||
+ stm32mp15xx-dhcor-avenger96.dts
|
||||
|
||||
Boot Sequences
|
||||
--------------
|
||||
|
||||
3 boot configurations are supported with:
|
||||
2 boot configurations are supported with:
|
||||
|
||||
+----------+------------------------+-------------------------+--------------+
|
||||
| **ROM** | **FSBL** | **SSBL** | **OS** |
|
||||
@ -83,14 +91,10 @@ defconfig_file : stm32mp15_trusted_defconfig
|
||||
| TrustZone |secure monitor |
|
||||
+-------------+-------------------------+------------+-------+
|
||||
|
||||
TF-A performs a full initialization of Secure peripherals and installs a
|
||||
secure monitor, BL32:
|
||||
|
||||
* SPMin provided by TF-A or
|
||||
* OP-TEE from specific partitions (teeh, teed, teex).
|
||||
|
||||
U-Boot is running in normal world and uses the secure monitor to access
|
||||
to secure resources.
|
||||
TF-A (BL2) initialize the DDR and loads the next stage binaries from a FIP file:
|
||||
+ BL32: a secure monitor BL32 = SPMin provided by TF-A or OP-TEE : performs a full initialization of Secure peripherals and provides service to normal world
|
||||
+ BL33: a non-trusted firmware = U-Boot, running in normal world and uses the secure monitor to access to secure resources.
|
||||
+ HW_CONFIG: The hardware configuration file = the U-Boot device tree
|
||||
|
||||
The **Basic** boot chain
|
||||
````````````````````````
|
||||
@ -123,19 +127,27 @@ the supported device trees for STM32MP15x are:
|
||||
|
||||
+ ev1: eval board with pmic stpmic1 (ev1 = mother board + daughter ed1)
|
||||
|
||||
+ stm32mp157a-ev1
|
||||
+ stm32mp157c-ev1
|
||||
+ stm32mp157d-ev1
|
||||
+ stm32mp157f-ev1
|
||||
|
||||
+ ed1: daughter board with pmic stpmic1
|
||||
|
||||
+ stm32mp157a-ed1
|
||||
+ stm32mp157c-ed1
|
||||
+ stm32mp157d-ed1
|
||||
+ stm32mp157f-ed1
|
||||
|
||||
+ dk1: Discovery board
|
||||
|
||||
+ stm32mp157a-dk1
|
||||
+ stm32mp157d-dk1
|
||||
|
||||
+ dk2: Discovery board = dk1 with a BT/WiFI combo and a DSI panel
|
||||
|
||||
+ stm32mp157c-dk2
|
||||
+ stm32mp157f-dk2
|
||||
|
||||
+ avenger96: Avenger96 board from Arrow Electronics based on DH Elec. DHCOR SoM
|
||||
|
||||
@ -223,16 +235,24 @@ Build Procedure
|
||||
|
||||
6. Output files
|
||||
|
||||
BootRom and TF-A expect binaries with STM32 image header
|
||||
SPL expects file with U-Boot uImage header
|
||||
The ROM code expects FSBL binaries with STM32 image header.
|
||||
TF-A expect a FIP binary, with OS monitor (SPmin or OP-TEE) and with U-Boot binary + device tree.
|
||||
SPL expects file with U-Boot uImage header.
|
||||
|
||||
So in the output directory (selected by KBUILD_OUTPUT),
|
||||
you can found the needed files:
|
||||
|
||||
- For **Trusted** boot (with or without OP-TEE)
|
||||
|
||||
- FSBL = **tf-a.stm32** (provided by TF-A compilation)
|
||||
- SSBL = **u-boot.stm32**
|
||||
- FSBL = **tf-a.stm32** and **tf-a-fip.bin** (provided by TF-A compilation)
|
||||
- SSBL = **u-boot-nodtb.bin** and **u-boot.dtb**
|
||||
|
||||
The file tf-a-fip.bin includes the 2 U-Boot files, u-boot-nodtb.bin and u-boot.dtb;
|
||||
they are needed during the TF-A compilation(BL33=u-boot-nodtb.bin BL33_CFG=u-boot.dtb).
|
||||
|
||||
You can also update a existing it with the tools provided by TF-A:
|
||||
|
||||
# fiptool update --nt-fw u-boot-nodtb.bin --hw-config u-boot.dtb tf-a-fip-stm32mp157c-ev1.bin
|
||||
|
||||
- For Basic boot
|
||||
|
||||
@ -298,22 +318,24 @@ Prepare an SD card
|
||||
The minimal requirements for STMP32MP15x boot up to U-Boot are:
|
||||
|
||||
- GPT partitioning (with gdisk or with sgdisk)
|
||||
- 2 fsbl partitions, named fsbl1 and fsbl2, size at least 256KiB
|
||||
- one ssbl partition for U-Boot
|
||||
- 2 fsbl partitions, named "fsbl1" and "fsbl2", size at least 256KiB
|
||||
- one partition named "fip" for FIP or U-Boot (TF-A search the "fip"
|
||||
partition and SPL search the 3th partition, because
|
||||
CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_PARTITION=3)
|
||||
|
||||
Then the minimal GPT partition is:
|
||||
|
||||
+-------+--------+---------+-------------+
|
||||
| *Num* | *Name* | *Size* | *Content* |
|
||||
+=======+========+=========+=============+
|
||||
| 1 | fsbl1 | 256 KiB | TF-A or SPL |
|
||||
+-------+--------+---------+-------------+
|
||||
| 2 | fsbl2 | 256 KiB | TF-A or SPL |
|
||||
+-------+--------+---------+-------------+
|
||||
| 3 | ssbl | enought | U-Boot |
|
||||
+-------+--------+---------+-------------+
|
||||
| 4 | <any> | <any> | Rootfs |
|
||||
+-------+--------+---------+-------------+
|
||||
+-------+--------+---------+------------------------------+
|
||||
| *Num* | *Name* | *Size* | *Content* |
|
||||
+=======+========+=========+==============================+
|
||||
| 1 | fsbl1 | 256 KiB | TF-A BL2 (tf-a.stm32) or SPL |
|
||||
+-------+--------+---------+------------------------------+
|
||||
| 2 | fsbl2 | 256 KiB | TF-A BL2 (tf-a.stm32) or SPL |
|
||||
+-------+--------+---------+------------------------------+
|
||||
| 3 | fip | enought | tf-a-fip.bin or u-boot.img |
|
||||
+-------+--------+---------+------------------------------+
|
||||
| 4 | <any> | <any> | Rootfs |
|
||||
+-------+--------+---------+------------------------------+
|
||||
|
||||
Add a 4th partition (Rootfs) marked bootable with a file extlinux.conf
|
||||
following the Generic Distribution feature (doc/README.distro for use).
|
||||
@ -334,7 +356,7 @@ b) create minimal image::
|
||||
# sgdisk --resize-table=128 -a 1 \
|
||||
-n 1:34:545 -c 1:fsbl1 \
|
||||
-n 2:546:1057 -c 2:fsbl2 \
|
||||
-n 3:1058:5153 -c 3:ssbl \
|
||||
-n 3:1058:5153 -c 3:fip \
|
||||
-n 4:5154: -c 4:rootfs \
|
||||
-p /dev/<SD card dev>
|
||||
|
||||
@ -353,7 +375,7 @@ c) copy the FSBL (2 times) and SSBL file on the correct partition.
|
||||
|
||||
# dd if=tf-a.stm32 of=/dev/mmcblk0p1
|
||||
# dd if=tf-a.stm32 of=/dev/mmcblk0p2
|
||||
# dd if=u-boot.stm32 of=/dev/mmcblk0p3
|
||||
# dd if=tf-a-fip.bin of=/dev/mmcblk0p3
|
||||
|
||||
To boot from SD card, select BootPinMode = 1 0 1 and reset.
|
||||
|
||||
@ -363,8 +385,8 @@ Prepare eMMC
|
||||
You can use U-Boot to copy binary in eMMC.
|
||||
|
||||
In the next example, you need to boot from SD card and the images
|
||||
(u-boot-spl.stm32, u-boot.img) are presents on SD card (mmc 0)
|
||||
in ext4 partition 4 (bootfs).
|
||||
(tf-a.stm32, tf-a-fip.bin / u-boot-spl.stm32, u-boot.img) are presents
|
||||
on SD card (mmc 0) in ext4 partition 4 (bootfs).
|
||||
|
||||
To boot from SD card, select BootPinMode = 1 0 1 and reset.
|
||||
|
||||
@ -373,13 +395,16 @@ Then you update the eMMC with the next U-Boot command :
|
||||
a) prepare GPT on eMMC,
|
||||
example with 2 partitions, bootfs and roots::
|
||||
|
||||
# setenv emmc_part "name=ssbl,size=2MiB;name=bootfs,type=linux,bootable,size=64MiB;name=rootfs,type=linux,size=512"
|
||||
# setenv emmc_part "name=fip,size=2MiB;name=bootfs,type=linux,bootable,size=64MiB;name=rootfs,type=linux,size=512"
|
||||
# gpt write mmc 1 ${emmc_part}
|
||||
|
||||
b) copy SPL on eMMC on firts boot partition
|
||||
(SPL max size is 256kB, with LBA 512, 0x200)::
|
||||
|
||||
# ext4load mmc 0:4 0xC0000000 tf-a.stm32
|
||||
or
|
||||
# ext4load mmc 0:4 0xC0000000 u-boot-spl.stm32
|
||||
|
||||
# mmc dev 1
|
||||
# mmc partconf 1 1 1 1
|
||||
# mmc write ${fileaddr} 0 200
|
||||
@ -387,7 +412,10 @@ b) copy SPL on eMMC on firts boot partition
|
||||
|
||||
c) copy U-Boot in first GPT partition of eMMC::
|
||||
|
||||
# ext4load mmc 0:4 0xC0000000 u-boo t.img
|
||||
# ext4load mmc 0:4 0xC0000000 tf-a-fip.bin
|
||||
or
|
||||
# ext4load mmc 0:4 0xC0000000 u-boot.img
|
||||
|
||||
# mmc dev 1
|
||||
# part start mmc 1 1 partstart
|
||||
# mmc write ${fileaddr} ${partstart} ${filesize}
|
||||
@ -520,14 +548,14 @@ On EV1 board, booting from SD card, without OP-TEE::
|
||||
dev: RAM alt: 2 name: uramdisk.image.gz layout: RAM_ADDR
|
||||
dev: eMMC alt: 3 name: mmc0_fsbl1 layout: RAW_ADDR
|
||||
dev: eMMC alt: 4 name: mmc0_fsbl2 layout: RAW_ADDR
|
||||
dev: eMMC alt: 5 name: mmc0_ssbl layout: RAW_ADDR
|
||||
dev: eMMC alt: 5 name: mmc0_fip layout: RAW_ADDR
|
||||
dev: eMMC alt: 6 name: mmc0_bootfs layout: RAW_ADDR
|
||||
dev: eMMC alt: 7 name: mmc0_vendorfs layout: RAW_ADDR
|
||||
dev: eMMC alt: 8 name: mmc0_rootfs layout: RAW_ADDR
|
||||
dev: eMMC alt: 9 name: mmc0_userfs layout: RAW_ADDR
|
||||
dev: eMMC alt: 10 name: mmc1_boot1 layout: RAW_ADDR
|
||||
dev: eMMC alt: 11 name: mmc1_boot2 layout: RAW_ADDR
|
||||
dev: eMMC alt: 12 name: mmc1_ssbl layout: RAW_ADDR
|
||||
dev: eMMC alt: 12 name: mmc1_fip layout: RAW_ADDR
|
||||
dev: eMMC alt: 13 name: mmc1_bootfs layout: RAW_ADDR
|
||||
dev: eMMC alt: 14 name: mmc1_vendorfs layout: RAW_ADDR
|
||||
dev: eMMC alt: 15 name: mmc1_rootfs layout: RAW_ADDR
|
||||
@ -548,14 +576,14 @@ All the supported device are exported for dfu-util tool::
|
||||
Found DFU: [0483:df11] ver=9999, devnum=99, cfg=1, intf=0, alt=15, name="mmc1_rootfs", serial="002700333338511934383330"
|
||||
Found DFU: [0483:df11] ver=9999, devnum=99, cfg=1, intf=0, alt=14, name="mmc1_vendorfs", serial="002700333338511934383330"
|
||||
Found DFU: [0483:df11] ver=9999, devnum=99, cfg=1, intf=0, alt=13, name="mmc1_bootfs", serial="002700333338511934383330"
|
||||
Found DFU: [0483:df11] ver=9999, devnum=99, cfg=1, intf=0, alt=12, name="mmc1_ssbl", serial="002700333338511934383330"
|
||||
Found DFU: [0483:df11] ver=9999, devnum=99, cfg=1, intf=0, alt=12, name="mmc1_fip", serial="002700333338511934383330"
|
||||
Found DFU: [0483:df11] ver=9999, devnum=99, cfg=1, intf=0, alt=11, name="mmc1_boot2", serial="002700333338511934383330"
|
||||
Found DFU: [0483:df11] ver=9999, devnum=99, cfg=1, intf=0, alt=10, name="mmc1_boot1", serial="002700333338511934383330"
|
||||
Found DFU: [0483:df11] ver=9999, devnum=99, cfg=1, intf=0, alt=9, name="mmc0_userfs", serial="002700333338511934383330"
|
||||
Found DFU: [0483:df11] ver=9999, devnum=99, cfg=1, intf=0, alt=8, name="mmc0_rootfs", serial="002700333338511934383330"
|
||||
Found DFU: [0483:df11] ver=9999, devnum=99, cfg=1, intf=0, alt=7, name="mmc0_vendorfs", serial="002700333338511934383330"
|
||||
Found DFU: [0483:df11] ver=9999, devnum=99, cfg=1, intf=0, alt=6, name="mmc0_bootfs", serial="002700333338511934383330"
|
||||
Found DFU: [0483:df11] ver=9999, devnum=99, cfg=1, intf=0, alt=5, name="mmc0_ssbl", serial="002700333338511934383330"
|
||||
Found DFU: [0483:df11] ver=9999, devnum=99, cfg=1, intf=0, alt=5, name="mmc0_fip", serial="002700333338511934383330"
|
||||
Found DFU: [0483:df11] ver=9999, devnum=99, cfg=1, intf=0, alt=4, name="mmc0_fsbl2", serial="002700333338511934383330"
|
||||
Found DFU: [0483:df11] ver=9999, devnum=99, cfg=1, intf=0, alt=3, name="mmc0_fsbl1", serial="002700333338511934383330"
|
||||
Found DFU: [0483:df11] ver=9999, devnum=99, cfg=1, intf=0, alt=2, name="uramdisk.image.gz", serial="002700333338511934383330"
|
||||
@ -566,9 +594,9 @@ You can update the boot device:
|
||||
|
||||
- SD card (mmc0) ::
|
||||
|
||||
$> dfu-util -d 0483:5720 -a 3 -D tf-a-stm32mp157c-ev1-trusted.stm32
|
||||
$> dfu-util -d 0483:5720 -a 4 -D tf-a-stm32mp157c-ev1-trusted.stm32
|
||||
$> dfu-util -d 0483:5720 -a 5 -D u-boot-stm32mp157c-ev1-trusted.img
|
||||
$> dfu-util -d 0483:5720 -a 3 -D tf-a-stm32mp157c-ev1.stm32
|
||||
$> dfu-util -d 0483:5720 -a 4 -D tf-a-stm32mp157c-ev1.stm32
|
||||
$> dfu-util -d 0483:5720 -a 5 -D tf-a-fip-stm32mp157c-ev1.bin
|
||||
$> dfu-util -d 0483:5720 -a 6 -D st-image-bootfs-openstlinux-weston-stm32mp1.ext4
|
||||
$> dfu-util -d 0483:5720 -a 7 -D st-image-vendorfs-openstlinux-weston-stm32mp1.ext4
|
||||
$> dfu-util -d 0483:5720 -a 8 -D st-image-weston-openstlinux-weston-stm32mp1.ext4
|
||||
@ -576,9 +604,9 @@ You can update the boot device:
|
||||
|
||||
- EMMC (mmc1)::
|
||||
|
||||
$> dfu-util -d 0483:5720 -a 10 -D tf-a-stm32mp157c-ev1-trusted.stm32
|
||||
$> dfu-util -d 0483:5720 -a 11 -D tf-a-stm32mp157c-ev1-trusted.stm32
|
||||
$> dfu-util -d 0483:5720 -a 12 -D u-boot-stm32mp157c-ev1-trusted.img
|
||||
$> dfu-util -d 0483:5720 -a 10 -D tf-a-stm32mp157c-ev1.stm32
|
||||
$> dfu-util -d 0483:5720 -a 11 -D tf-a-stm32mp157c-ev1.stm32
|
||||
$> dfu-util -d 0483:5720 -a 12 -D tf-a-fip-stm32mp157c-ev1.bin
|
||||
$> dfu-util -d 0483:5720 -a 13 -D st-image-bootfs-openstlinux-weston-stm32mp1.ext4
|
||||
$> dfu-util -d 0483:5720 -a 14 -D st-image-vendorfs-openstlinux-weston-stm32mp1.ext4
|
||||
$> dfu-util -d 0483:5720 -a 15 -D st-image-weston-openstlinux-weston-stm32mp1.ext4
|
||||
@ -595,14 +623,14 @@ only the MTD partition on the boot devices are available, for example:
|
||||
|
||||
- NOR (nor0 = alt 20) & NAND (nand0 = alt 26) ::
|
||||
|
||||
$> dfu-util -d 0483:5720 -a 21 -D tf-a-stm32mp157c-ev1-trusted.stm32
|
||||
$> dfu-util -d 0483:5720 -a 22 -D tf-a-stm32mp157c-ev1-trusted.stm32
|
||||
$> dfu-util -d 0483:5720 -a 23 -D u-boot-stm32mp157c-ev1-trusted.img
|
||||
$> dfu-util -d 0483:5720 -a 21 -D tf-a-stm32mp157c-ev1.stm32
|
||||
$> dfu-util -d 0483:5720 -a 22 -D tf-a-stm32mp157c-ev1.stm32
|
||||
$> dfu-util -d 0483:5720 -a 23 -D tf-a-fip-stm32mp157c-ev1.bin
|
||||
$> dfu-util -d 0483:5720 -a 27 -D st-image-weston-openstlinux-weston-stm32mp1_nand_4_256_multivolume.ubi
|
||||
|
||||
- NAND (nand0 = alt 21)::
|
||||
|
||||
$> dfu-util -d 0483:5720 -a 22 -D tf-a-stm32mp157c-ev1-trusted.stm32
|
||||
$> dfu-util -d 0483:5720 -a 23 -D u-boot-stm32mp157c-ev1-trusted.img
|
||||
$> dfu-util -d 0483:5720 -a 24 -D u-boot-stm32mp157c-ev1-trusted.img
|
||||
$> dfu-util -d 0483:5720 -a 22 -D tf-a-stm32mp157c-ev1.stm32
|
||||
$> dfu-util -d 0483:5720 -a 23 -D tf-a-fip-stm32mp157c-ev1.bin
|
||||
$> dfu-util -d 0483:5720 -a 24 -D tf-a-fip-stm32mp157c-ev1.bin
|
||||
$> dfu-util -d 0483:5720 -a 25 -D st-image-weston-openstlinux-weston-stm32mp1_nand_4_256_multivolume.ubi
|
||||
|
||||
197
doc/device-tree-bindings/arm/arm,scmi.txt
Normal file
197
doc/device-tree-bindings/arm/arm,scmi.txt
Normal file
@ -0,0 +1,197 @@
|
||||
System Control and Management Interface (SCMI) Message Protocol
|
||||
----------------------------------------------------------
|
||||
|
||||
The SCMI is intended to allow agents such as OSPM to manage various functions
|
||||
that are provided by the hardware platform it is running on, including power
|
||||
and performance functions.
|
||||
|
||||
This binding is intended to define the interface the firmware implementing
|
||||
the SCMI as described in ARM document number ARM DEN 0056A ("ARM System Control
|
||||
and Management Interface Platform Design Document")[0] provide for OSPM in
|
||||
the device tree.
|
||||
|
||||
Required properties:
|
||||
|
||||
The scmi node with the following properties shall be under the /firmware/ node.
|
||||
|
||||
- compatible : shall be "arm,scmi" or "arm,scmi-smc" for smc/hvc transports
|
||||
- mboxes: List of phandle and mailbox channel specifiers. It should contain
|
||||
exactly one or two mailboxes, one for transmitting messages("tx")
|
||||
and another optional for receiving the notifications("rx") if
|
||||
supported.
|
||||
- shmem : List of phandle pointing to the shared memory(SHM) area as per
|
||||
generic mailbox client binding.
|
||||
- #address-cells : should be '1' if the device has sub-nodes, maps to
|
||||
protocol identifier for a given sub-node.
|
||||
- #size-cells : should be '0' as 'reg' property doesn't have any size
|
||||
associated with it.
|
||||
- arm,smc-id : SMC id required when using smc or hvc transports
|
||||
|
||||
Optional properties:
|
||||
|
||||
- mbox-names: shall be "tx" or "rx" depending on mboxes entries.
|
||||
|
||||
See Documentation/devicetree/bindings/mailbox/mailbox.txt for more details
|
||||
about the generic mailbox controller and client driver bindings.
|
||||
|
||||
The mailbox is the only permitted method of calling the SCMI firmware.
|
||||
Mailbox doorbell is used as a mechanism to alert the presence of a
|
||||
messages and/or notification.
|
||||
|
||||
Each protocol supported shall have a sub-node with corresponding compatible
|
||||
as described in the following sections. If the platform supports dedicated
|
||||
communication channel for a particular protocol, the 3 properties namely:
|
||||
mboxes, mbox-names and shmem shall be present in the sub-node corresponding
|
||||
to that protocol.
|
||||
|
||||
Clock/Performance bindings for the clocks/OPPs based on SCMI Message Protocol
|
||||
------------------------------------------------------------
|
||||
|
||||
This binding uses the common clock binding[1].
|
||||
|
||||
Required properties:
|
||||
- #clock-cells : Should be 1. Contains the Clock ID value used by SCMI commands.
|
||||
|
||||
Power domain bindings for the power domains based on SCMI Message Protocol
|
||||
------------------------------------------------------------
|
||||
|
||||
This binding for the SCMI power domain providers uses the generic power
|
||||
domain binding[2].
|
||||
|
||||
Required properties:
|
||||
- #power-domain-cells : Should be 1. Contains the device or the power
|
||||
domain ID value used by SCMI commands.
|
||||
|
||||
Sensor bindings for the sensors based on SCMI Message Protocol
|
||||
--------------------------------------------------------------
|
||||
SCMI provides an API to access the various sensors on the SoC.
|
||||
|
||||
Required properties:
|
||||
- #thermal-sensor-cells: should be set to 1. This property follows the
|
||||
thermal device tree bindings[3].
|
||||
|
||||
Valid cell values are raw identifiers (Sensor ID)
|
||||
as used by the firmware. Refer to platform details
|
||||
for your implementation for the IDs to use.
|
||||
|
||||
Reset signal bindings for the reset domains based on SCMI Message Protocol
|
||||
------------------------------------------------------------
|
||||
|
||||
This binding for the SCMI reset domain providers uses the generic reset
|
||||
signal binding[5].
|
||||
|
||||
Required properties:
|
||||
- #reset-cells : Should be 1. Contains the reset domain ID value used
|
||||
by SCMI commands.
|
||||
|
||||
SRAM and Shared Memory for SCMI
|
||||
-------------------------------
|
||||
|
||||
A small area of SRAM is reserved for SCMI communication between application
|
||||
processors and SCP.
|
||||
|
||||
The properties should follow the generic mmio-sram description found in [4]
|
||||
|
||||
Each sub-node represents the reserved area for SCMI.
|
||||
|
||||
Required sub-node properties:
|
||||
- reg : The base offset and size of the reserved area with the SRAM
|
||||
- compatible : should be "arm,scmi-shmem" for Non-secure SRAM based
|
||||
shared memory
|
||||
|
||||
[0] http://infocenter.arm.com/help/topic/com.arm.doc.den0056a/index.html
|
||||
[1] Documentation/devicetree/bindings/clock/clock-bindings.txt
|
||||
[2] Documentation/devicetree/bindings/power/power-domain.yaml
|
||||
[3] Documentation/devicetree/bindings/thermal/thermal.txt
|
||||
[4] Documentation/devicetree/bindings/sram/sram.yaml
|
||||
[5] Documentation/devicetree/bindings/reset/reset.txt
|
||||
|
||||
Example:
|
||||
|
||||
sram@50000000 {
|
||||
compatible = "mmio-sram";
|
||||
reg = <0x0 0x50000000 0x0 0x10000>;
|
||||
|
||||
#address-cells = <1>;
|
||||
#size-cells = <1>;
|
||||
ranges = <0 0x0 0x50000000 0x10000>;
|
||||
|
||||
cpu_scp_lpri: scp-shmem@0 {
|
||||
compatible = "arm,scmi-shmem";
|
||||
reg = <0x0 0x200>;
|
||||
};
|
||||
|
||||
cpu_scp_hpri: scp-shmem@200 {
|
||||
compatible = "arm,scmi-shmem";
|
||||
reg = <0x200 0x200>;
|
||||
};
|
||||
};
|
||||
|
||||
mailbox@40000000 {
|
||||
....
|
||||
#mbox-cells = <1>;
|
||||
reg = <0x0 0x40000000 0x0 0x10000>;
|
||||
};
|
||||
|
||||
firmware {
|
||||
|
||||
...
|
||||
|
||||
scmi {
|
||||
compatible = "arm,scmi";
|
||||
mboxes = <&mailbox 0 &mailbox 1>;
|
||||
mbox-names = "tx", "rx";
|
||||
shmem = <&cpu_scp_lpri &cpu_scp_hpri>;
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
scmi_devpd: protocol@11 {
|
||||
reg = <0x11>;
|
||||
#power-domain-cells = <1>;
|
||||
};
|
||||
|
||||
scmi_dvfs: protocol@13 {
|
||||
reg = <0x13>;
|
||||
#clock-cells = <1>;
|
||||
};
|
||||
|
||||
scmi_clk: protocol@14 {
|
||||
reg = <0x14>;
|
||||
#clock-cells = <1>;
|
||||
};
|
||||
|
||||
scmi_sensors0: protocol@15 {
|
||||
reg = <0x15>;
|
||||
#thermal-sensor-cells = <1>;
|
||||
};
|
||||
|
||||
scmi_reset: protocol@16 {
|
||||
reg = <0x16>;
|
||||
#reset-cells = <1>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
cpu@0 {
|
||||
...
|
||||
reg = <0 0>;
|
||||
clocks = <&scmi_dvfs 0>;
|
||||
};
|
||||
|
||||
hdlcd@7ff60000 {
|
||||
...
|
||||
reg = <0 0x7ff60000 0 0x1000>;
|
||||
clocks = <&scmi_clk 4>;
|
||||
power-domains = <&scmi_devpd 1>;
|
||||
resets = <&scmi_reset 10>;
|
||||
};
|
||||
|
||||
thermal-zones {
|
||||
soc_thermal {
|
||||
polling-delay-passive = <100>;
|
||||
polling-delay = <1000>;
|
||||
/* sensor ID */
|
||||
thermal-sensors = <&scmi_sensors0 3>;
|
||||
...
|
||||
};
|
||||
};
|
||||
@ -45,6 +45,8 @@ Required properties:
|
||||
- #phy-cells: see phy-bindings.txt in the same directory, must be <0> for PHY
|
||||
port#1 and must be <1> for PHY port#2, to select USB controller
|
||||
|
||||
Optional properties:
|
||||
- vbus-supply: phandle to the regulator providing 5V vbus to the USB connector
|
||||
|
||||
Example:
|
||||
usbphyc: usb-phy@5a006000 {
|
||||
|
||||
@ -159,6 +159,14 @@ config CLK_CDCE9XX
|
||||
Enable the clock synthesizer driver for CDCE913/925/937/949
|
||||
series of chips.
|
||||
|
||||
config CLK_SCMI
|
||||
bool "Enable SCMI clock driver"
|
||||
depends on SCMI_FIRMWARE
|
||||
help
|
||||
Enable this option if you want to support clock devices exposed
|
||||
by a SCMI agent based on SCMI clock protocol communication
|
||||
with a SCMI server.
|
||||
|
||||
source "drivers/clk/analogbits/Kconfig"
|
||||
source "drivers/clk/at91/Kconfig"
|
||||
source "drivers/clk/exynos/Kconfig"
|
||||
|
||||
@ -32,6 +32,7 @@ obj-$(CONFIG_CLK_MPC83XX) += mpc83xx_clk.o
|
||||
obj-$(CONFIG_CLK_OCTEON) += clk_octeon.o
|
||||
obj-$(CONFIG_CLK_OWL) += owl/
|
||||
obj-$(CONFIG_CLK_RENESAS) += renesas/
|
||||
obj-$(CONFIG_CLK_SCMI) += clk_scmi.o
|
||||
obj-$(CONFIG_CLK_SIFIVE) += sifive/
|
||||
obj-$(CONFIG_ARCH_SUNXI) += sunxi/
|
||||
obj-$(CONFIG_CLK_STM32F) += clk_stm32f.o
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user