Commit 575aa6a7 authored by Henrik Fegran's avatar Henrik Fegran Committed by udinator
Browse files

Issue #778 fix, change mie behavior in setup_mmode_reg


Signed-off-by: default avatarHenrik Fegran <Henrik.Fegran@silabs.com>
parent a73e0b84
......@@ -89,7 +89,8 @@ class riscv_privileged_common_seq extends uvm_sequence;
mstatus.set_field("SPP", 0);
// Enable interrupt
mstatus.set_field("MPIE", cfg.enable_interrupt);
mstatus.set_field("MIE", cfg.enable_interrupt);
// MIE is set when returning with mret, avoids trapping before returning
mstatus.set_field("MIE", 0);
mstatus.set_field("SPIE", cfg.enable_interrupt);
mstatus.set_field("SIE", cfg.enable_interrupt);
mstatus.set_field("UPIE", cfg.enable_interrupt);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment