Skip to content

Commit

Permalink
fix #2657
Browse files Browse the repository at this point in the history
set bit0 of PMPADDR as read only zero
  • Loading branch information
JeanRochCoulon authored Dec 9, 2024
1 parent ed89c71 commit e1eebe8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/csr_regfile.sv
Original file line number Diff line number Diff line change
Expand Up @@ -1709,7 +1709,7 @@ module csr_regfile
automatic logic [11:0] index = csr_addr.address[11:0] - riscv::CSR_PMPADDR0;
// check if the entry or the entry above is locked
if (!pmpcfg_q[index].locked && !(pmpcfg_q[index+1].locked && pmpcfg_q[index+1].addr_mode == riscv::TOR)) begin
pmpaddr_d[index] = csr_wdata[CVA6Cfg.PLEN-3:0];
pmpaddr_d[index] = {csr_wdata[CVA6Cfg.PLEN-3:1], 1'b0};
end
end
default: update_access_exception = 1'b1;
Expand Down

0 comments on commit e1eebe8

Please sign in to comment.