Describe the issue
The documentation for xTaskCreateRestrictedStatic states that the portMPU_REGION_* macros are to be used. Most ARM ports follow this API. However, the CM33 port (and maybe other ARMv8 as well) do not follow this convention, but instead use the tskMPU_REGION_* macros.
Using the portMPU_REGION_*_SHAREABLE attributes clashes with the access attributes. Shareability cannot be configured (see also #1383), and using the corresponding macros in the call to xTaskCreateRestrictedStatic can override the access attributes.
This deviation could be classified as a "bug", but the different attributes (cacheability) are encoded in different registers, and therefore cannot - as in other ARM ports, be expressed as a bitwise OR of the single flags in a single register. So I think the documented API cannot be implemented for this port.
The documentation should
- state that different ports use different APIs
- list both API variants
- either list which ports use which API, or explain how to find out which API a specific port uses
Reference
https://www.freertos.org/Documentation/02-Kernel/04-API-references/13-FreeRTOS-MPU-specific/02-xTaskCreateRestrictedStatic
Screenshot
Browser
- Browser: Firefox
- Version: any
See also: https://forums.freertos.org/t/shareable-mpu-regions-for-dma-on-cortex-m33/24918
Describe the issue
The documentation for xTaskCreateRestrictedStatic states that the
portMPU_REGION_*macros are to be used. Most ARM ports follow this API. However, the CM33 port (and maybe other ARMv8 as well) do not follow this convention, but instead use thetskMPU_REGION_*macros.Using the
portMPU_REGION_*_SHAREABLEattributes clashes with the access attributes. Shareability cannot be configured (see also #1383), and using the corresponding macros in the call toxTaskCreateRestrictedStaticcan override the access attributes.This deviation could be classified as a "bug", but the different attributes (cacheability) are encoded in different registers, and therefore cannot - as in other ARM ports, be expressed as a bitwise OR of the single flags in a single register. So I think the documented API cannot be implemented for this port.
The documentation should
Reference
https://www.freertos.org/Documentation/02-Kernel/04-API-references/13-FreeRTOS-MPU-specific/02-xTaskCreateRestrictedStatic
Screenshot
Browser
See also: https://forums.freertos.org/t/shareable-mpu-regions-for-dma-on-cortex-m33/24918