Skip to content

docs: clarify MPU region parameter macros#1445

Merged
rawalexe merged 1 commit into
FreeRTOS:mainfrom
Old-Ding:codex/docs-mpu-region-parameter-macros
Jul 10, 2026
Merged

docs: clarify MPU region parameter macros#1445
rawalexe merged 1 commit into
FreeRTOS:mainfrom
Old-Ding:codex/docs-mpu-region-parameter-macros

Conversation

@Old-Ding

@Old-Ding Old-Ding commented Jul 4, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Clarify that MemoryRegion_t.ulParameters uses port-specific MPU region parameter macros.
  • Keep the existing portMPU_REGION_* examples for Cortex-M3/4 MPU ports.
  • Document that ARMv8-M MPU ports such as CM23, CM33, CM52, CM55, CM85, and STAR_MC3 use the tskMPU_REGION_* values from task.h, which the port translates into MPU register settings.

Fixes #1384

Impact

This is a documentation-only change. It does not change any API, ABI, macro value, structure layout, configuration option, or port behavior.

Validation

  • git diff --check -- include/task.h
  • git diff --stat and git diff --word-diff -- include/task.h
  • rg -n "Some ports, including the Cortex-M3/4 MPU ports|ARMv8-M MPU ports|MemoryRegion_t\.ulParameters|tskMPU_REGION|portMPU_REGION|xTaskCreateRestrictedStatic|vTaskAllocateMPURegions" include/task.h
  • Static source check: ARMv8-M ports consume tskMPU_REGION_* from MemoryRegion_t.ulParameters.
  • Static source check: Cortex-M3/4 MPU ports still consume portMPU_REGION_* from MemoryRegion_t.ulParameters.

Doxygen output was not generated locally because doxygen is not installed in this environment.

@Old-Ding Old-Ding force-pushed the codex/docs-mpu-region-parameter-macros branch from d216b6c to 9946ce8 Compare July 4, 2026 08:58
@Old-Ding Old-Ding changed the title [codex] clarify MPU region parameter macros docs: clarify MPU region parameter macros Jul 4, 2026
@Old-Ding Old-Ding marked this pull request as ready for review July 4, 2026 18:15
@Old-Ding Old-Ding force-pushed the codex/docs-mpu-region-parameter-macros branch from 9946ce8 to f42bfb3 Compare July 9, 2026 01:59
Document that MemoryRegion_t.ulParameters macros are port specific so users select the tskMPU_REGION_* or portMPU_REGION_* values that match their MPU port.

Signed-off-by: Old-Ding <ai.neo.ae86@gmail.com>
@rawalexe rawalexe force-pushed the codex/docs-mpu-region-parameter-macros branch from f42bfb3 to 1b177e5 Compare July 9, 2026 23:29
@sonarqubecloud

sonarqubecloud Bot commented Jul 9, 2026

Copy link
Copy Markdown

@rawalexe rawalexe left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good clarification for a common source of confusion between portMPU_REGION_* and tskMPU_REGION_* macros across MPU port variants. No logic changes, comment-only. LGTM.

@rawalexe rawalexe merged commit 9db704c into FreeRTOS:main Jul 10, 2026
17 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[DOC] API deviation for CM33 port is not documented

4 participants