projects
/
riscv-isa-sim.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
17f497c
)
Initialize mstatus.prv1/prv2 to U, not S
author
Andrew Waterman
<waterman@cs.berkeley.edu>
Fri, 11 Sep 2015 22:13:26 +0000
(15:13 -0700)
committer
Andrew Waterman
<waterman@cs.berkeley.edu>
Fri, 11 Sep 2015 22:13:26 +0000
(15:13 -0700)
This doesn't really matter, but it matches Rocket.
riscv/processor.cc
patch
|
blob
|
history
diff --git
a/riscv/processor.cc
b/riscv/processor.cc
index e14859e773894839c59d9b64adad9e47e84dbc81..962e9cd39f4226828b7b460ed3a2e2758a3217a1 100644
(file)
--- a/
riscv/processor.cc
+++ b/
riscv/processor.cc
@@
-107,8
+107,8
@@
void state_t::reset()
{
memset(this, 0, sizeof(*this));
mstatus = set_field(mstatus, MSTATUS_PRV, PRV_M);
- mstatus = set_field(mstatus, MSTATUS_PRV1, PRV_
S
);
- mstatus = set_field(mstatus, MSTATUS_PRV2, PRV_
S
);
+ mstatus = set_field(mstatus, MSTATUS_PRV1, PRV_
U
);
+ mstatus = set_field(mstatus, MSTATUS_PRV2, PRV_
U
);
pc = DEFAULT_MTVEC + 0x100;
load_reservation = -1;
}