Skip to content

Commit

Permalink
use dcache_assoc_width (#2640)
Browse files Browse the repository at this point in the history
cva6/core/cache_subsystem/wt_dcache_missunit.sv

Line 202 in b718824
 .OutWidth ($clog2(CVA6Cfg.DCACHE_SET_ASSOC)) 

Better to use the width parameter which already contemplates the case of 0 to avoid issues if associativity is set to 1
cva6/core/include/build_config_pkg.sv

Line 134 in b718824
 cfg.DCACHE_SET_ASSOC_WIDTH = CVA6Cfg.DcacheSetAssoc > 1 ? $clog2(CVA6Cfg.DcacheSetAssoc) : CVA6Cfg.DcacheSetAssoc;
  • Loading branch information
AngelaGonzalezMarino authored Dec 2, 2024
1 parent 84e3a39 commit ba8ac71
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/cache_subsystem/wt_dcache_missunit.sv
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,7 @@ module wt_dcache_missunit
// generate random cacheline index
lfsr #(
.LfsrWidth(8),
.OutWidth ($clog2(CVA6Cfg.DCACHE_SET_ASSOC))
.OutWidth (CVA6Cfg.DCACHE_SET_ASSOC_WIDTH)
) i_lfsr_inv (
.clk_i (clk_i),
.rst_ni(rst_ni),
Expand Down

0 comments on commit ba8ac71

Please sign in to comment.