Skip to content

Commit

Permalink
[tlul,rtl] Remove a term in tlul_adapter_reg's instr_error signal
Browse files Browse the repository at this point in the history
The instr_error signal is only used in an OR with tl_err. If the
instr_type field is invalid then u_err (a tlul_err instance) will
cause tl_err to be high (because it's equivalent check will fail). So
there's no need to test it explicitly here.

Note that the instr_error signal is still worth having, because it
allows us to spot when someone does a TL transaction whose user bits
claim to be of "instruction type" but where en_ifetch_i is false.

Signed-off-by: Rupert Swarbrick <rswarbrick@lowrisc.org>
  • Loading branch information
rswarbrick committed Oct 9, 2024
1 parent 2cebfb9 commit 98a3d29
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions hw/ip/tlul/rtl/tlul_adapter_reg.sv
Original file line number Diff line number Diff line change
Expand Up @@ -199,10 +199,8 @@ module tlul_adapter_reg
////////////////////

// An instruction type transaction is only valid if en_ifetch is enabled
// If the instruction type is completely invalid, also considered an instruction error
assign instr_error = prim_mubi_pkg::mubi4_test_invalid(tl_i.a_user.instr_type) |
(prim_mubi_pkg::mubi4_test_true_strict(tl_i.a_user.instr_type) &
prim_mubi_pkg::mubi4_test_false_loose(en_ifetch_i));
assign instr_error = prim_mubi_pkg::mubi4_test_true_strict(tl_i.a_user.instr_type) &
prim_mubi_pkg::mubi4_test_false_loose(en_ifetch_i);

assign err_internal = addr_align_err | tl_err | instr_error | intg_error;

Expand Down

0 comments on commit 98a3d29

Please sign in to comment.