Skip to content

Commit

Permalink
Hardwire the reserved bits of the PMPCFG CSR to 0
Browse files Browse the repository at this point in the history
This realigns CVA6 with spike (#1346)

Signed-off-by: Moritz Schneider <[email protected]>
  • Loading branch information
Moschn committed Sep 7, 2023
1 parent 0da4dff commit 4c663fc
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions core/csr_regfile.sv
Original file line number Diff line number Diff line change
Expand Up @@ -908,6 +908,9 @@ module csr_regfile import ariane_pkg::*; #(
// hardwired extension registers
mstatus_d.sd = (mstatus_q.xs == riscv::Dirty) | (mstatus_q.fs == riscv::Dirty);

// reserve PMPCFG bits 5 and 6 (hardwire to 0)
for (int i = 0; i < NrPMPEntries; i++) pmpcfg_d[i].reserved = 2'b0;

// write the floating point status register
if (csr_write_fflags_i) begin
fcsr_d.fflags = csr_wdata_i[4:0] | fcsr_q.fflags;
Expand Down

0 comments on commit 4c663fc

Please sign in to comment.