Skip to content

Commit

Permalink
[dv] Expand documentation comments about gaps in bit_bash_seq
Browse files Browse the repository at this point in the history
We also change the behaviour slightly: we only need to set bits of
mode that will be read in the for loop below, and matching that upper
bound explicitly avoids us needing to mention `UVM_REG_DATA_WIDTH.

This is only really for setting up debug messages anyway, so shouldn't
matter all that much.

Signed-off-by: Rupert Swarbrick <[email protected]>
  • Loading branch information
rswarbrick authored and cfrantz committed Jun 14, 2024
1 parent 8ad3f01 commit 38f578e
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions hw/dv/sv/csr_utils/csr_seq_lib.sv
Original file line number Diff line number Diff line change
Expand Up @@ -404,7 +404,7 @@ class csr_bit_bash_seq extends csr_base_seq;
no_cmp = is_excl(fields[j], CsrExclInitCheck, CsrBitBashTest) ||
is_excl(fields[j], CsrExclWriteCheck, CsrBitBashTest) ;

// Any unused bits on the right side of the LSB?
// Any unused bits below the LSB of this field?
while (next_lsb < lsb) mode[next_lsb++] = "RO";

repeat (w) begin
Expand All @@ -415,8 +415,8 @@ class csr_bit_bash_seq extends csr_base_seq;
end
end

// Any unused bits on the left side of the MSB?
while (next_lsb < `UVM_REG_DATA_WIDTH) begin
// Any unused bits above the top field, but that we will still look at with bash_kth_bit?
while (next_lsb < n_bits) begin
mode[next_lsb++] = "RO";
end

Expand Down

0 comments on commit 38f578e

Please sign in to comment.