ibndias
ibndias

Reputation: 117

RISC-V PMP Address Configuration

I am currently learning about PMP in RISC-V, I understand about the TOR, but I'm getting difficulties to understand NA4 and NAPOT configuration

enter image description here

Can someone make an explanation ? My assumption is, if my pmpaddr is 0xFFFFFFFE then it means my pmp ranges from 0xFFFFFFFE00 to 0xFFFFFFFEFF. Is this right?

Upvotes: 2

Views: 2607

Answers (1)

iamywang
iamywang

Reputation: 41

I can give you the answrer.
if pmpaddr is 0xFFFFFFFE, (1111....1110), it will matches address from 1111....111000 to 1111...111111(8 bytes).
The length of pmpaddr is 32 bits, and the length of memory is 34 bits.
You can understand this with subnet mask of IP addr.
This means the last zero is the indicator bit, the high bits must all match.

Upvotes: 4

Related Questions