STM32CubeMX user interface

UM1718

 

 

Figure 88. STM32H7 dual-core: GPIOs context assignment

4.7Enabling security in Pinout & Configuration view (STM32L5 and STM32U5 series only)

The STM32L5 MCU series harnesses the security features of the Arm Cortex-M33 processor and its TrustZone® for Armv8-M combined with ST security implementation.

STM32L5 MCUs support

two levels of privilege

unprivileged: software has limited access to system resources

privileged: software has full access to system resources, subject to security restrictions

two security states, Secure and Non-secure: TrustZone® security is activated when the TZEN option bit is set in the FLASH_OPTR register. Security states are orthogonal to mode and privilege, therefore, each security state supports execution in both modes and both levels of privilege.

In STM32CubeMX the choice to activate TrustZone® is made at project creation (see Section 4.2: New Project window). When TrustZone® is enabled, STM32CubeMX Pinout & Configuration view is adjusted accordingly with a split between secure (M33S) and non-secure context (M33NS), and more security-related configuration options (see

Figure 89).

116/453

UM1718 Rev 41

UM1718

STM32CubeMX user interface

 

 

Figure 89. Pinout & Configuration view for Trustzone®-enabled projects

4.7.1Privilege access for peripherals, GPIO EXTIs and DMA requests

 

Independently of TrustZone®, STM32CubeMX enables privilege access:

 

for each peripheral: in the GTZC configuration panel (see Section 4.7.5), as shown in

 

Figure 90

 

for each GPIO EXTI: in the GPIO configuration panel, as shown in Figure 91

 

for each DMA channel: in the DMA configuration panel (see Section 4.7.4), as shown in

 

Figure 92.

Note:

When TrustZone® is active, either all or none of the RCC registers can be put in privilege

 

mode. In STM32CubeMX, this is done by selecting “Privileged-only attribute” check box

 

from RCC mode panel (see Figure 93). In privilege mode, all RCC registers configuration

 

are reserved for the privilege application through the PWR_CR_PRIVEN bit, which is

 

secured when Trustzone® is activated.

UM1718 Rev 41

117/453

STM32CubeMX user interface

UM1718

 

 

Figure 90. Setting privileges for peripherals

118/453

UM1718 Rev 41

UM1718

STM32CubeMX user interface

 

 

Figure 91. Setting privileges for GPIO EXTIs

UM1718 Rev 41

119/453

STM32CubeMX user interface

UM1718

 

 

 

 

Figure 92. Configuring security and privilege of DMA requests

 

 

 

 

Figure 93. RCC privilege mode

120/453

UM1718 Rev 41

Соседние файлы в папке STM