Home /Modules/cpu/REGISTERS.md

REGISTERS.md

lib/cpu/cortex-m/REGISTERS.md · 29 line(s) · markdown

Cortex-M Registers

Core registers

Special registers

CONTROL, PRIMASK, BASEPRI, FAULTMASK, IPSR, MSP, PSP, and other special registers are profile- and privilege-dependent. BASEPRI and FAULTMASK, for example, are not available identically on all baseline profiles. Implement access checks rather than exposing every register universally.

Optional register banks

Modeling requirements

  1. Keep register width and reset values in the selected profile/implementation definition.
  2. Implement read/write side effects for special registers.
  3. Enforce privilege and security attribution restrictions.
  4. Preserve architecturally defined reserved-bit behavior; do not invent meanings for reserved bits.
  5. Record unknown or vendor-specific register behavior as unspecified until configured.