Registered User mNo edit summary |
Registered User Tag: 2017 source edit |
||
(30 intermediate revisions by 7 users not shown) | |||
Line 1: | Line 1: | ||
{{ApplicableFor | |||
|MPUs list=STM32MP13x, STM32MP15x, STM32MP21x, STM32MP23x, STM32MP25x | |||
|MPUs checklist=STM32MP13x, STM32MP15x, STM32MP21x, STM32MP23x, STM32MP25x | |||
}} | |||
==Article purpose== | ==Article purpose== | ||
The purpose of this article is to | The purpose of this article is to: | ||
* briefly introduce the SDMMC peripheral and its main features | * briefly introduce the SDMMC peripheral and its main features, | ||
* indicate the | * indicate the peripheral instances assignment at boot time and their assignment at runtime (including whether instances can be allocated to secure contexts), | ||
* list the software frameworks and drivers managing the peripheral, | |||
* explain | * explain how to configure the peripheral. | ||
==Peripheral overview== | ==Peripheral overview== | ||
The '''SDMMC''' peripheral is used to interconnect STM32 MPU to SD memory cards, SDIO and MMC devices. | The '''SDMMC''' peripheral is used to interconnect STM32 MPU to SD memory cards, SDIO and MMC devices. | ||
Refer to the [[STM32 MPU resources#Reference manuals|STM32 MPU reference manuals]] for the complete list of features, and to the software frameworks and drivers, introduced below, to see which features are implemented. | |||
Refer to the [[ | |||
== | ==Peripheral usage== | ||
This chapter is applicable in the scope of the '''OpenSTLinux BSP''' running on the Arm<sup>®</sup> Cortex<sup>®</sup>-A processor(s), and the '''FwST-M Package''' running on the Arm<sup>®</sup> Cortex<sup>®</sup>-M processor. | |||
===Boot time assignment=== | |||
By default, in [[OpenSTLinux distribution]], SDMMC1 is the instance used to boot on SD memory cards when SDMMC2 is the instance used to boot on MMC Flash devices. | |||
== | ====On {{MicroprocessorDevice | device=1}}==== | ||
== | |||
SDMMC1/2 instances can be used to support memory boot on SD or MMC Flash devices. | SDMMC1/2 instances can be used to support memory boot on SD or MMC Flash devices. | ||
The SDMMC3 is not used at boot time. | The SDMMC3 (only present on {{MicroprocessorDevice | device=15}}) is not used at boot time. | ||
{{Info | The SDMMC instances are ordered by address in the [[Device tree|device tree]] {{CodeSource | Linux kernel | arch/arm/boot/dts/ | {{Info | The SDMMC instances are ordered by address in the [[Device tree|device tree]] {{CodeSource | Linux kernel | arch/arm/boot/dts/st/stm32mp151.dtsi}} file for {{MicroprocessorDevice | device=15}}: | ||
sdmmc3: sdmmc@48004000 { | |||
... | |||
sdmmc1: sdmmc@58005000 { | |||
... | |||
sdmmc2: sdmmc@58007000 { | |||
By default, in [[OpenSTLinux distribution]], '''sdmmc3 is disabled''' so the sdmmc1 (SD card on [[STM32MP157x-EV1_-_hardware_description|Evaluation boards]] and [[STM32MP157x-DKx_-_hardware_description|Discovery kits]]) and sdmmc2 (eMMC on [[STM32MP157x-EV1_-_hardware_description|Evaluation boards]] and Wifi on [[STM32MP157x-DKx_-_hardware_description|Discovery kits]]) are respectively aliased to mmc0 and mmc1.<br> | By default, in [[OpenSTLinux distribution]], '''sdmmc3 is disabled''' so the sdmmc1 (SD card on [[STM32MP157x-EV1_-_hardware_description|Evaluation boards]] and [[STM32MP157x-DKx_-_hardware_description|Discovery kits]]) and sdmmc2 (eMMC on [[STM32MP157x-EV1_-_hardware_description|Evaluation boards]] and Wifi on [[STM32MP157x-DKx_-_hardware_description|Discovery kits]]) are respectively aliased to mmc0 and mmc1.<br> | ||
'''If you enable sdmmc3''', it will take the mmc0 alias and the aliases above will shift, so don't forget to update the Linux kernel boot command accordingly!<br> | '''If you enable sdmmc3''', it will take the mmc0 alias and the aliases above will shift, so don't forget to update the Linux kernel boot command accordingly!<br> | ||
For instance, 'root=/dev/mmcblk0p6' will become 'root=/dev/mmcblk1p6' to mount the rootfs from the sdmmc1 (SD card) when sdmmc3 is enabled.}} | For instance, 'root=/dev/mmcblk0p6' will become 'root=/dev/mmcblk1p6' to mount the rootfs from the sdmmc1 (SD card) when sdmmc3 is enabled.}} | ||
{{#lst:STM32MP1_internal_peripherals_assignment_table_template|stm32mp1_boottime}} | |||
<section begin=stm32mp13_boottime /><section begin=stm32mp15_boottime /> | |||
| rowspan="2" | Mass storage | |||
| rowspan="2" | [[SDMMC internal peripheral|SDMMC]] | |||
| SDMMC1 | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| | |||
|- | |||
| SDMMC2 | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| | |||
|- | |||
<section end=stm32mp13_boottime /><section end=stm32mp15_boottime /> | |||
|} | |||
=== | ====On {{MicroprocessorDevice | device=2}}==== | ||
=====For {{TrustedDomainFlavor|flavor=A35-TD}}===== | |||
{{#lst:STM32MP2_internal_peripherals_assignment_table_template|stm32mp2_a35_boottime}} | |||
<section begin=stm32mp21_a35_boottime/><section begin=stm32mp23_a35_boottime/><section begin=stm32mp25_a35_boottime/> | |||
| rowspan="3" | Mass storage | |||
| rowspan="3" | [[SDMMC internal peripheral | SDMMC]] | |||
| SDMMC1 | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| <span title="assigned peripheral" style="font-size:21px">☐</span> | |||
| | |||
|- | |||
| SDMMC2 | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| <span title="assigned peripheral" style="font-size:21px">☐</span> | |||
| | |||
|- | |||
| SDMMC3 | |||
| | |||
| | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| | |||
|- | |||
<section end=stm32mp21_a35_boottime/><section end=stm32mp23_a35_boottime/><section end=stm32mp25_a35_boottime/> | |||
|} | |||
=====For {{TrustedDomainFlavor|flavor=M33-TD}}===== | |||
{{#lst:STM32MP2_internal_peripherals_assignment_table_template|stm32mp2_m33_boottime}} | |||
<section begin=stm32mp21_m33_boottime/><section begin=stm32mp23_m33_boottime/><section begin=stm32mp25_m33_boottime/> | |||
| rowspan="3" | Mass storage | |||
| rowspan="3" | [[SDMMC internal peripheral | SDMMC]] | |||
| SDMMC1 | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| | |||
|- | |||
| SDMMC2 | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| | |||
|- | |||
| SDMMC3 | |||
| | |||
| | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| | |||
| | |||
|- | |||
<section end=stm32mp21_m33_boottime/><section end=stm32mp23_m33_boottime/><section end=stm32mp25_m33_boottime/> | |||
|} | |||
==== | ===Runtime assignment=== | ||
====On {{MicroprocessorDevice | device=13}}==== | |||
{{#lst:STM32MP1_internal_peripherals_assignment_table_template|stm32mp13_runtime}} | |||
<section begin=stm32mp13_runtime /> | |||
| rowspan="2" | Mass storage | |||
| rowspan="2" | [[SDMMC internal peripheral|SDMMC]] | |||
| SDMMC1 | |||
| <span title="assignable peripheral but not supported" style="font-size:21px">⬚</span> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| Assignment (single choice) | |||
|- | |||
| SDMMC2 | |||
| <span title="assignable peripheral but not supported" style="font-size:21px">⬚</span> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| Assignment (single choice) | |||
|- | |||
<section end=stm32mp13_runtime /> | |||
|} | |||
==== | ====On {{MicroprocessorDevice | device=15}}==== | ||
{{: | {{#lst:STM32MP1_internal_peripherals_assignment_table_template|stm32mp15_runtime}} | ||
<section begin=stm32mp15_runtime /> | |||
| rowspan="3" | Mass storage | |||
| rowspan="3" | [[SDMMC internal peripheral|SDMMC]] | |||
| SDMMC1 | |||
| | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| | |||
| | |||
|- | |||
| SDMMC2 | |||
| | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| | |||
| | | | ||
|- | |||
| SDMMC3 | |||
| | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| Assignment (single choice) | |||
|- | |||
<section end=stm32mp15_runtime /> | |||
|} | |||
==== | ====On {{MicroprocessorDevice | device=21}}==== | ||
The | The tables below are applicable to any {{TrustedDomainFlavor | flavor=Any-TD}}. | ||
{{#lst:STM32MP2_internal_peripherals_assignment_table_template|stm32mp21_runtime}} | |||
<section begin=stm32mp21_a35_runtime /><section begin=stm32mp21_m33_runtime /> | |||
| rowspan="3" | Mass storage | |||
| rowspan="3" | [[SDMMC internal peripheral | SDMMC]] | |||
| SDMMC1 | |||
| <span title="assignable peripheral but not supported" style="font-size:21px">⬚</span><sup>OP-TEE</sup> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| | |||
|- | |||
| SDMMC2 | |||
| <span title="assignable peripheral but not supported" style="font-size:21px">⬚</span><sup>OP-TEE</sup> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| | |||
|- | |||
| SDMMC3 | |||
| <span title="assignable peripheral but not supported" style="font-size:21px">⬚</span><sup>OP-TEE</sup> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| | |||
|- | |||
<section end=stm32mp21_a35_runtime /><section end=stm32mp21_m33_runtime /> | |||
|} | |||
====On {{MicroprocessorDevice | device=23}}==== | |||
The tables below are applicable to any {{TrustedDomainFlavor | flavor=Any-TD}}. | |||
{{#lst:STM32MP2_internal_peripherals_assignment_table_template|stm32mp23_runtime}} | |||
<section begin=stm32mp23_a35_runtime /><section begin=stm32mp23_m33_runtime /> | |||
| rowspan="3" | Mass storage | |||
| rowspan="3" | [[SDMMC internal peripheral | SDMMC]] | |||
| SDMMC1 | |||
| <span title="assignable peripheral but not supported" style="font-size:21px">⬚</span><sup>OP-TEE</sup> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| | |||
|- | |||
| SDMMC2 | |||
| <span title="assignable peripheral but not supported" style="font-size:21px">⬚</span><sup>OP-TEE</sup> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| | |||
|- | |||
| SDMMC3 | |||
| <span title="assignable peripheral but not supported" style="font-size:21px">⬚</span><sup>OP-TEE</sup> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| | |||
|- | |||
<section end=stm32mp23_a35_runtime /><section end=stm32mp23_m33_runtime /> | |||
|} | |||
====On {{MicroprocessorDevice | device=25}}==== | |||
The tables below are applicable to any {{TrustedDomainFlavor | flavor=Any-TD}}. | |||
{{#lst:STM32MP2_internal_peripherals_assignment_table_template|stm32mp25_runtime}} | |||
<section begin=stm32mp25_a35_runtime /><section begin=stm32mp25_m33_runtime /> | |||
| rowspan="3" | Mass storage | |||
| rowspan="3" | [[SDMMC internal peripheral | SDMMC]] | |||
| SDMMC1 | |||
| <span title="assignable peripheral but not supported" style="font-size:21px">⬚</span><sup>OP-TEE</sup> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| | |||
| | |||
|- | |||
| SDMMC2 | |||
| <span title="assignable peripheral but not supported" style="font-size:21px">⬚</span><sup>OP-TEE</sup> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| | |||
| | |||
|- | |||
| SDMMC3 | |||
| <span title="assignable peripheral but not supported" style="font-size:21px">⬚</span><sup>OP-TEE</sup> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| | |||
| | |||
|- | |||
<section end=stm32mp25_a35_runtime /><section end=stm32mp25_m33_runtime /> | |||
|} | |||
== | ==Software frameworks and drivers== | ||
Below are listed the software frameworks and drivers managing the SDMMC peripheral for the embedded software components listed in the above tables. | |||
* '''Linux<sup>®</sup>''': [[MMC overview|Linux MMC framework]] | |||
* '''STM32Cube''': [[STM32CubeMP15 Package architecture|SDMMC HAL driver]] and {{CodeSource | STM32CubeMP1 | Drivers/STM32MP1xx_HAL_Driver/Inc/stm32mp1xx_hal_sd.h | header file of SD HAL module}} | |||
* '''TF-A BL2''': MMC framework ({{CodeSource | TF-A | drivers/mmc/mmc.c}}) and driver ({{CodeSource | TF-A | drivers/st/mmc/stm32_sdmmc2.c}}) | |||
* '''U-Boot''': MMC framework ({{CodeSource | U-Boot | drivers/mmc/mmc.c}}) and driver ({{CodeSource | U-Boot | drivers/mmc/stm32_sdmmc2.c}}) | |||
== | ==How to assign and configure the peripheral== | ||
< | The peripheral assignment can be done via the [[STM32CubeMX]] graphical tool (and manually completed if needed).<br /> | ||
This tool also helps to configure the peripheral: | |||
* partial device trees (pin control and clock tree) generation for the OpenSTLinux software components, | |||
* HAL initialization code generation for the STM32CubeMPU Package. | |||
The configuration is applied by the firmware running in the context in which the peripheral is assigned. | |||
For Linux<sup>®</sup> kernel configuration, please refer to [[SDMMC device tree configuration]]. | |||
<noinclude> | <noinclude> | ||
[[Category:High speed interface peripherals]] | |||
[[Category:Mass storage peripherals]] | |||
{{ArticleBasedOnModel | Internal peripheral article model}} | {{ArticleBasedOnModel | Internal peripheral article model}} | ||
{{PublicationRequestId | 8316 | 2018-08-06 | AnneJ}} | {{PublicationRequestId | 8316 | 2018-08-06 | AnneJ}} | ||
</noinclude> | </noinclude> |
Latest revision as of 10:17, 22 May 2025
1. Article purpose[edit | edit source]
The purpose of this article is to:
- briefly introduce the SDMMC peripheral and its main features,
- indicate the peripheral instances assignment at boot time and their assignment at runtime (including whether instances can be allocated to secure contexts),
- list the software frameworks and drivers managing the peripheral,
- explain how to configure the peripheral.
2. Peripheral overview[edit | edit source]
The SDMMC peripheral is used to interconnect STM32 MPU to SD memory cards, SDIO and MMC devices.
Refer to the STM32 MPU reference manuals for the complete list of features, and to the software frameworks and drivers, introduced below, to see which features are implemented.
3. Peripheral usage[edit | edit source]
This chapter is applicable in the scope of the OpenSTLinux BSP running on the Arm® Cortex®-A processor(s), and the FwST-M Package running on the Arm® Cortex®-M processor.
3.1. Boot time assignment[edit | edit source]
By default, in OpenSTLinux distribution, SDMMC1 is the instance used to boot on SD memory cards when SDMMC2 is the instance used to boot on MMC Flash devices.
3.1.1. On STM32MP1 series[edit | edit source]
SDMMC1/2 instances can be used to support memory boot on SD or MMC Flash devices.
The SDMMC3 (only present on STM32MP15x lines ) is not used at boot time.
![]() |
The SDMMC instances are ordered by address in the device tree arch/arm/boot/dts/st/stm32mp151.dtsi file for STM32MP15x lines ![]() sdmmc3: sdmmc@48004000 {
...
sdmmc1: sdmmc@58005000 {
...
sdmmc2: sdmmc@58007000 {
By default, in OpenSTLinux distribution, sdmmc3 is disabled so the sdmmc1 (SD card on Evaluation boards and Discovery kits) and sdmmc2 (eMMC on Evaluation boards and Wifi on Discovery kits) are respectively aliased to mmc0 and mmc1. |
Click on to expand or collapse the legend...
Domain | Peripheral | Boot time allocation | Comment ![]() | |||
---|---|---|---|---|---|---|
Instance | Cortex-A7 secure (ROM code) |
Cortex-A7 secure (TF-A BL2) |
Cortex-A7 nonsecure (U-Boot) | |||
Mass storage | SDMMC | SDMMC1 | ☐ | ☐ | ☐ | |
SDMMC2 | ☐ | ☐ | ☐ |
3.1.2. On STM32MP2 series[edit | edit source]
3.1.2.1. For A35-TD flavor
[edit | edit source]
Click on to expand or collapse the legend...
Domain | Peripheral | Boot time allocation | Comment ![]() | |||
---|---|---|---|---|---|---|
Instance | Cortex-A35 secure (ROM code) |
Cortex-A35 secure (TF-A BL2) |
Cortex-A35 nonsecure (U-Boot) | |||
Mass storage | SDMMC | SDMMC1 | ☐ | ☐ | ☐ | |
SDMMC2 | ☐ | ☐ | ☐ | |||
SDMMC3 | ☐ |
3.1.2.2. For M33-TD flavor
[edit | edit source]
Click on to expand or collapse the legend...
Domain | Peripheral | Boot time allocation | Comment ![]() | ||||
---|---|---|---|---|---|---|---|
Instance | Cortex-A35 secure (ROM code) |
Cortex-A35 secure (TF-A BL2) |
Cortex-A35 nonsecure (U-Boot) |
Cortex-M33 secure (MCUboot) | |||
Mass storage | SDMMC | SDMMC1 | ☐ | ☐ | ☐ | ☐ | |
SDMMC2 | ☐ | ☐ | ☐ | ☐ | |||
SDMMC3 | ☐ |
3.2. Runtime assignment[edit | edit source]
3.2.1. On STM32MP13x lines
[edit | edit source]
Click on to expand or collapse the legend...
Domain | Peripheral | Runtime allocation | Comment ![]() | ||
---|---|---|---|---|---|
Instance | Cortex-A7 secure (OP-TEE) |
Cortex-A7 nonsecure (Linux) | |||
Mass storage | SDMMC | SDMMC1 | ⬚ | ☐ | Assignment (single choice) |
SDMMC2 | ⬚ | ☐ | Assignment (single choice) |
3.2.2. On STM32MP15x lines
[edit | edit source]
Click on to expand or collapse the legend...
Domain | Peripheral | Runtime allocation | Comment ![]() | |||
---|---|---|---|---|---|---|
Instance | Cortex-A7 secure (OP-TEE) |
Cortex-A7 nonsecure (Linux) |
Cortex-M4 (STM32Cube) | |||
Mass storage | SDMMC | SDMMC1 | ☐ | |||
SDMMC2 | ☐ | |||||
SDMMC3 | ☐ | ☐ | Assignment (single choice) |
3.2.3. On STM32MP21x lines
[edit | edit source]
The tables below are applicable to any TD flavor (A35-TD or M33-TD) .
Click on to expand or collapse the legend...
Domain | Peripheral | Runtime allocation | Comment ![]() | ||||
---|---|---|---|---|---|---|---|
Instance | Cortex-A35 secure (OP-TEE / TF-A BL31) |
Cortex-A35 nonsecure (Linux) |
Cortex-M33 secure (TF-M) |
Cortex-M33 nonsecure (STM32Cube) | |||
Mass storage | SDMMC | SDMMC1 | ⬚OP-TEE | ☐ | ☐ | ☐ | |
SDMMC2 | ⬚OP-TEE | ☐ | ☐ | ☐ | |||
SDMMC3 | ⬚OP-TEE | ☐ | ☐ | ☐ |
3.2.4. On STM32MP23x lines
[edit | edit source]
The tables below are applicable to any TD flavor (A35-TD or M33-TD) .
Click on to expand or collapse the legend...
Domain | Peripheral | Runtime allocation | Comment ![]() | ||||
---|---|---|---|---|---|---|---|
Instance | Cortex-A35 secure (OP-TEE / TF-A BL31) |
Cortex-A35 nonsecure (Linux) |
Cortex-M33 secure (TF-M) |
Cortex-M33 nonsecure (STM32Cube) | |||
Mass storage | SDMMC | SDMMC1 | ⬚OP-TEE | ☐ | ☐ | ☐ | |
SDMMC2 | ⬚OP-TEE | ☐ | ☐ | ☐ | |||
SDMMC3 | ⬚OP-TEE | ☐ | ☐ | ☐ |
3.2.5. On STM32MP25x lines
[edit | edit source]
The tables below are applicable to any TD flavor (A35-TD or M33-TD) .
Click on to expand or collapse the legend...
Domain | Peripheral | Runtime allocation | Comment ![]() | |||||
---|---|---|---|---|---|---|---|---|
Instance | Cortex-A35 secure (OP-TEE / TF-A BL31) |
Cortex-A35 nonsecure (Linux) |
Cortex-M33 secure (TF-M) |
Cortex-M33 nonsecure (STM32Cube) |
Cortex-M0+ (STM32Cube) | |||
Mass storage | SDMMC | SDMMC1 | ⬚OP-TEE | ☐ | ☐ | ☐ | ||
SDMMC2 | ⬚OP-TEE | ☐ | ☐ | ☐ | ||||
SDMMC3 | ⬚OP-TEE | ☐ | ☐ | ☐ |
4. Software frameworks and drivers[edit | edit source]
Below are listed the software frameworks and drivers managing the SDMMC peripheral for the embedded software components listed in the above tables.
- Linux®: Linux MMC framework
- STM32Cube: SDMMC HAL driver and header file of SD HAL module
- TF-A BL2: MMC framework (drivers/mmc/mmc.c ) and driver (drivers/st/mmc/stm32_sdmmc2.c )
- U-Boot: MMC framework (drivers/mmc/mmc.c ) and driver (drivers/mmc/stm32_sdmmc2.c )
5. How to assign and configure the peripheral[edit | edit source]
The peripheral assignment can be done via the STM32CubeMX graphical tool (and manually completed if needed).
This tool also helps to configure the peripheral:
- partial device trees (pin control and clock tree) generation for the OpenSTLinux software components,
- HAL initialization code generation for the STM32CubeMPU Package.
The configuration is applied by the firmware running in the context in which the peripheral is assigned.
For Linux® kernel configuration, please refer to SDMMC device tree configuration.