Skip to content

Commit

Permalink
Hardwire the reserved bits of the PMPCFG CSR to 0 (openhwgroup#1368)
Browse files Browse the repository at this point in the history
  • Loading branch information
JeanRochCoulon authored Sep 11, 2023
2 parents 00f113b + 4c663fc commit de986ed
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 de986ed

Please sign in to comment.