Skip to content

Commit d0cada9

Browse files
Merge pull request #847 from Silabs-ArjanB/ArjanB_nos1
Signal rename
2 parents c2c6148 + 9acc3b9 commit d0cada9

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

rtl/cv32e40x_controller_bypass.sv

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -147,9 +147,9 @@ module cv32e40x_controller_bypass import cv32e40x_pkg::*;
147147
(ex_wb_pipe_i.instr_valid && (ex_wb_pipe_i.csr_en || (ex_wb_pipe_i.sys_en && ex_wb_pipe_i.sys_mret_insn) || ex_wb_pipe_i.instr_meta.clic_ptr || ex_wb_pipe_i.instr_meta.mret_ptr))
148148
);
149149

150-
// Stall ID when WFI or WFE is active in EX.
151-
// Prevent load/store following a WFI or WFE in the pipeline
152-
assign ctrl_byp_o.wfi_wfe_stall = (id_ex_pipe_i.sys_en && (id_ex_pipe_i.sys_wfi_insn || id_ex_pipe_i.sys_wfe_insn) && id_ex_pipe_i.instr_valid);
150+
// Stall ID when instruction that can trigger sleep (e.g. WFI or WFE) is active in EX.
151+
// Prevent load/store following a sleep instruction in the pipeline
152+
assign ctrl_byp_o.sleep_stall = (id_ex_pipe_i.sys_en && (id_ex_pipe_i.sys_wfi_insn || id_ex_pipe_i.sys_wfe_insn) && id_ex_pipe_i.instr_valid);
153153

154154
// Stall ID when mnxti CSR is accessed in EX
155155
// This is needed because the data bypass from EX uses csr_rdata, and for mnxti this is actually mstatus and not the result

rtl/cv32e40x_controller_fsm.sv

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
// //
2222
// Additional contributions by: //
2323
// //
24-
// Design Name: cv32e40x_controller_fsm //
24+
// Design Name: cv32e40x_controller_fsm //
2525
// Project Name: CV32E40X //
2626
// Language: SystemVerilog //
2727
// //
@@ -651,7 +651,7 @@ module cv32e40x_controller_fsm import cv32e40x_pkg::*;
651651
// - If not checking for id_stage_haltable for interrupts and debug, the core could end up in a situation where it tries to create a bubble
652652
// by halting ID, but the condition disallowing interrupt or debug will not disappear until the sequence currently handled by the ID stage
653653
// is done. This would create an unrecoverable deadlock.
654-
ctrl_fsm_o.halt_id = (ctrl_byp_i.jalr_stall || ctrl_byp_i.load_stall || ctrl_byp_i.csr_stall || ctrl_byp_i.wfi_wfe_stall || ctrl_byp_i.mnxti_id_stall) ||
654+
ctrl_fsm_o.halt_id = (ctrl_byp_i.jalr_stall || ctrl_byp_i.load_stall || ctrl_byp_i.csr_stall || ctrl_byp_i.sleep_stall || ctrl_byp_i.mnxti_id_stall) ||
655655
((pending_interrupt || pending_nmi || pending_nmi_early) && debug_interruptible && id_stage_haltable) ||
656656
((pending_async_debug || pending_sync_debug) && id_stage_haltable);
657657

rtl/include/cv32e40x_pkg.sv

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1309,7 +1309,7 @@ typedef struct packed {
13091309
logic jalr_stall; // Stall due to JALR hazard (JALR used result from EX or LSU result in WB)
13101310
logic load_stall; // Stall due to load operation
13111311
logic csr_stall;
1312-
logic wfi_wfe_stall;
1312+
logic sleep_stall; // Stall ID due to sleep (e.g. WFI, WFE) instruction in EX
13131313
logic mnxti_id_stall; // Stall ID due to mnxti CSR access in EX
13141314
logic mnxti_ex_stall; // Stall EX due to LSU instruction in WB
13151315
logic minstret_stall; // Stall due to minstret/h read in EX

0 commit comments

Comments
 (0)