projects
/
riscv-tests.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Don't assume PRV1/2 and IE1/2 are reset
[riscv-tests.git]
/
isa
/
rv64si
/
dirty.S
diff --git
a/isa/rv64si/dirty.S
b/isa/rv64si/dirty.S
index 78e333b62995714cccf891d4c5013a3fcf301840..e5f4db63e385e196f3400b4ab599c4f7f82cc280 100644
(file)
--- a/
isa/rv64si/dirty.S
+++ b/
isa/rv64si/dirty.S
@@
-19,7
+19,7
@@
RVTEST_CODE_BEGIN
la a1, page_table_1
csrw sptbr, a1
sfence.vm
- li a1, (
MSTATUS_VM & ~(MSTATUS_VM<<1)) * VM_SV43
+ li a1, (
(MSTATUS_VM & ~(MSTATUS_VM<<1)) * VM_SV43) | ((MSTATUS_PRV1 & ~(MSTATUS_PRV1<<1)) * PRV_S)
csrs mstatus, a1
la a1, 1f
csrw mepc, a1