riscv-non-isa / iopmp-spec

This repository contains the specification source for the RISC-V IOPMP Specification. This document proposes a Physical Memory Protection Unit of Input/Output devices, IOPMP for short, to regulate the accesses issued from the bus masters.
https://jira.riscv.org/browse/RVG-56
Creative Commons Attribution 4.0 International
15 stars 4 forks source link

Issue regarding SRCMD Table Protection #18

Closed YazanHussnain-10x closed 2 weeks ago

YazanHussnain-10x commented 2 weeks ago

In section 3.5.1, the specs states that:

In Format 2, MDLCK.md[m] locks both SRCMD_PERM(m).r and SRCMD_PERM(m).w. For MD m≥32, one should use MDLCKH.mdh to lock corresponding bits.

Given that in Format 2, SRCMD_PERM is indexed by md_num, this means that both SRCMD_PERM(m) and SRCMD_PERMH(m) are indexed by MD m. I believe MDLCK.md[m] should lock both SRCMD_PERM(m).r/w and SRCMD_PERMH(m).r/w not only SRCMD_PERM(m).r/w.

YazanHussnain-10x commented 2 weeks ago

@tyshyu @paul-andes

tyshyu commented 2 weeks ago

You are correct. MDLCK.md[m] should lock both SRCMD_PERM(m) and SRCMD_PERMH(m). The description in Section 3.5.1 should be fixed in future release.

Thank you for your feedback.