renesas / fsp

Flexible Software Package (FSP) for Renesas RA MCU Family
https://renesas.github.io/fsp/
Other
182 stars 82 forks source link

OFS1_SEL Incorrect and Missing Settings for TrustZone Projects #319

Closed GodavarthyAravinda closed 5 months ago

GodavarthyAravinda commented 8 months ago

Issue

For devices that support the OFS1_SEL register, BSP support for OFS1_SEL configuration had incorrect and missing settings for TrustZone projects (Secure and Non-secure projects).

The presence of an LVD1 module stack would incorrectly control the OFS1_SEL configuration for LVD0 settings for TrustZone projects.If an LVD1 module stack was not present, OFS1_SEL would be configured to load LVD0 settings from OFS1.If an LVD1 module stack was present, OFS1_SEL would be configured to load LVD0 settings from OFS1_SEC.

The OFS1_SEL configuration for PGAn settings was missing for TrustZone projects for RA6T2. With missing configuration, OFS1_SEL would be configured to load PGAn settings from OFS1_SEC. Affected devices:

Workaround

Now changed, all devices that support the OFS1_SEL register now support configuration of all OFS1_SEL settings for TrustZone projects, except for HOCO settings which remain automatically configured. LVD0 settings are now configurable within OFS1_SEL for all devices, and PGAn settings are now configurable within OFS1_SEL for RA6T2. For flat projects, no migration effort is required. For TrustZone projects, both Secure and Non-secure, review and update the OFS1_SEL configuration as necessary.