Skip to content

Commit

Permalink
In controller FSM DECODE_HWLOOP state, aligned ebreak and ecall manag…
Browse files Browse the repository at this point in the history
…ement to DECODE state.

Signed-off-by: Pascal Gouedo <[email protected]>
  • Loading branch information
Pascal Gouedo committed Nov 27, 2023
1 parent 1d0ec8d commit b94c429
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions rtl/cv32e40p_controller.sv
Original file line number Diff line number Diff line change
Expand Up @@ -766,7 +766,7 @@ module cv32e40p_controller import cv32e40p_pkg::*;

ebrk_insn_i: begin
halt_if_o = 1'b1;
halt_id_o = 1'b1;
halt_id_o = 1'b0;

if (debug_mode_q)
// we got back to the park loop in the debug rom
Expand All @@ -778,15 +778,15 @@ module cv32e40p_controller import cv32e40p_pkg::*;

else begin
// otherwise just a normal ebreak exception
ctrl_fsm_ns = FLUSH_EX;
ctrl_fsm_ns = id_ready_i ? FLUSH_EX : DECODE_HWLOOP;
end

end

ecall_insn_i: begin
halt_if_o = 1'b1;
halt_id_o = 1'b1;
ctrl_fsm_ns = FLUSH_EX;
halt_id_o = 1'b0;
ctrl_fsm_ns = id_ready_i ? FLUSH_EX : DECODE_HWLOOP;
end

csr_status_i: begin
Expand Down

0 comments on commit b94c429

Please sign in to comment.