diff options
author | Saleem Abdulrasool <compnerd@compnerd.org> | 2021-05-05 11:34:44 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-05-05 11:34:44 -0700 |
commit | c624e731bd95b61f7f08b885b1897fdb5ccaee00 (patch) | |
tree | 026c52bc3e5efab3c8c57541b00723472011f546 | |
parent | 12edfed73d2f601f7a23fded0d40a68cee958a2c (diff) | |
download | riscv-pk-c624e731bd95b61f7f08b885b1897fdb5ccaee00.zip riscv-pk-c624e731bd95b61f7f08b885b1897fdb5ccaee00.tar.gz riscv-pk-c624e731bd95b61f7f08b885b1897fdb5ccaee00.tar.bz2 |
replace `sbadaddr` with `stval` (#243)
This replaces use of the old `sbadaddr` CSR name with the current
`stval` name. The old spelling is not supported by the LLVM IAS,
however, the modern spelling is supported by both LLVM and binutils.
-rw-r--r-- | machine/mtrap.c | 2 | ||||
-rw-r--r-- | pk/entry.S | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/machine/mtrap.c b/machine/mtrap.c index 1acf802..1794675 100644 --- a/machine/mtrap.c +++ b/machine/mtrap.c @@ -178,7 +178,7 @@ send_ipi: void redirect_trap(uintptr_t epc, uintptr_t mstatus, uintptr_t badaddr) { - write_csr(sbadaddr, badaddr); + write_csr(stval, badaddr); write_csr(sepc, epc); write_csr(scause, read_csr(mcause)); write_csr(mepc, read_csr(stvec)); @@ -40,7 +40,7 @@ csrrw t0,sscratch,x0 csrr s0,sstatus csrr t1,sepc - csrr t2,sbadaddr + csrr t2,stval csrr t3,scause STORE t0,2*REGBYTES(x2) STORE s0,32*REGBYTES(x2) |