@@ -21,7 +21,6 @@ module csr_regfile
21
21
parameter type irq_ctrl_t = logic ,
22
22
parameter type scoreboard_entry_t = logic ,
23
23
parameter type rvfi_probes_csr_t = logic ,
24
- parameter int AsidWidth = 1 ,
25
24
parameter int unsigned MHPMCounterNum = 6
26
25
) (
27
26
// Subsystem Clock - SUBSYSTEM
@@ -100,7 +99,7 @@ module csr_regfile
100
99
// TO_BE_COMPLETED - EX_STAGE
101
100
output logic [CVA6Cfg.PPNW - 1 : 0 ] satp_ppn_o,
102
101
// TO_BE_COMPLETED - EX_STAGE
103
- output logic [AsidWidth - 1 : 0 ] asid_o,
102
+ output logic [CVA6Cfg. ASID_WIDTH - 1 : 0 ] asid_o,
104
103
// external interrupt in - SUBSYSTEM
105
104
input logic [1 : 0 ] irq_i,
106
105
// inter processor interrupt -> connected to machine mode sw - SUBSYSTEM
@@ -828,9 +827,9 @@ module csr_regfile
828
827
// intercept SATP writes if in S-Mode and TVM is enabled
829
828
if (priv_lvl_o == riscv :: PRIV_LVL_S && mstatus_q.tvm) update_access_exception = 1'b1 ;
830
829
else begin
831
- satp = satp_t ' (csr_wdata);
830
+ satp = satp_t ' (csr_wdata);
832
831
// only make ASID_LEN - 1 bit stick, that way software can figure out how many ASID bits are supported
833
- satp.asid = satp.asid & {{ (CVA6Cfg.ASIDW - AsidWidth ) { 1'b0 }} , { AsidWidth { 1'b1 }}} ;
832
+ satp.asid = satp.asid & {{ (CVA6Cfg.ASIDW - CVA6Cfg. ASID_WIDTH ) { 1'b0 }} , { CVA6Cfg. ASID_WIDTH { 1'b1 }}} ;
834
833
// only update if we actually support this mode
835
834
if (config_pkg :: vm_mode_t ' (satp.mode) == config_pkg :: ModeOff ||
836
835
config_pkg :: vm_mode_t ' (satp.mode) == CVA6Cfg.MODE_SV )
@@ -1551,7 +1550,7 @@ module csr_regfile
1551
1550
assign fprec_o = fcsr_q.fprec;
1552
1551
// MMU outputs
1553
1552
assign satp_ppn_o = satp_q.ppn;
1554
- assign asid_o = satp_q.asid[AsidWidth - 1 : 0 ];
1553
+ assign asid_o = satp_q.asid[CVA6Cfg. ASID_WIDTH - 1 : 0 ];
1555
1554
assign sum_o = mstatus_q.sum;
1556
1555
// we support bare memory addressing and SV39
1557
1556
assign en_translation_o = ((CVA6Cfg.RVS && config_pkg :: vm_mode_t ' (satp_q.mode) == CVA6Cfg.MODE_SV ) &&
0 commit comments