aboutsummaryrefslogtreecommitdiff
path: root/riscv/insns/dret.h
blob: 35c19cb8a29090b774ff8c7a1fa091aa36428e21 (plain)
1
2
3
4
5
6
7
8
9
require_privilege(PRV_M);
set_pc_and_serialize(STATE.dpc);
p->set_privilege(STATE.dcsr.prv);

/* We're not in Debug Mode anymore. */
STATE.dcsr.cause = 0;

if (STATE.dcsr.step)
  STATE.single_step = STATE.STEP_STEPPING;