Skip to content

Conversation

fsammoura1980
Copy link
Contributor

Factor out the logic for reading PMP configuration registers (pmpcfgX) from dump_pmp_regs into a new static inline helper function, z_riscv_pmp_read_config.

This new function encapsulates the architecture-specific (RV32/RV64) and slot-count-specific reads of the pmpcfg CSRs, improving code organization and potential reusability.

@zephyrbot zephyrbot added the area: RISCV RISCV Architecture (32-bit & 64-bit) label Oct 6, 2025
@fsammoura1980 fsammoura1980 force-pushed the pmpcfg_helpers branch 2 times, most recently from a60b606 to 416a805 Compare October 7, 2025 02:32
Factor out the logic for reading PMP configuration registers (pmpcfgX)
from dump_pmp_regs into a new static inline helper function,
z_riscv_pmp_read_config.

This new function encapsulates the architecture-specific (RV32/RV64)
and slot-count-specific reads of the pmpcfg CSRs, improving code
organization and potential reusability.

Signed-off-by: Firas Sammoura <fsammoura@google.com>
Copy link

sonarqubecloud bot commented Oct 7, 2025

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: RISCV RISCV Architecture (32-bit & 64-bit)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants