Skip to content

fix: normalize reserved W-only PMP permissions - #71

Open
KnightGOKU wants to merge 1 commit into
XUANTIE-RV:mainfrom
KnightGOKU:fix/openc910-pmpcfg-warL-w-only
Open

KnightGOKU wants to merge 1 commit into
XUANTIE-RV:mainfrom
KnightGOKU:fix/openc910-pmpcfg-warL-w-only

Conversation

@KnightGOKU

Copy link
Copy Markdown

Fixes #56

Summary

OpenC910 currently preserves the reserved PMP permission encoding R=0, W=1. This value should not be exposed as a valid PMP configuration.

Changes

  • Normalize the W bit for all PMP entries.
  • W is retained only when the corresponding R bit is set.
  • For example, writing 0x0a now reads back as 0x08.

Validation

A focused Verilator RTL test confirms that W-only permissions are normalized correctly. The corresponding baseline test fails because the original RTL preserves 0x0a.

The change is limited to PMP configuration WARL handling.

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.

OpenC910: Reserved W-only PMP permissions are preserved on readback

1 participant