diff options
| author | rewine <[email protected]> | 2022-07-10 17:48:57 +0800 |
|---|---|---|
| committer | GitHub <[email protected]> | 2022-07-10 17:48:57 +0800 |
| commit | 825b9ffbc3dd1308cf07ecaf7ade1cad5c84136a (patch) | |
| tree | 593f320713e05b6916fd69152a3b4ace9ee50473 | |
| parent | e36e3fda0c3e21ce3263144cfacb89e25e60f70d (diff) | |
[libcpu/risc-v/virt64]: fix parameter for call handle_trap (#6042)
| -rw-r--r-- | libcpu/risc-v/virt64/interrupt_gcc.S | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/libcpu/risc-v/virt64/interrupt_gcc.S b/libcpu/risc-v/virt64/interrupt_gcc.S index 730fa10d61..d9b7a06d98 100644 --- a/libcpu/risc-v/virt64/interrupt_gcc.S +++ b/libcpu/risc-v/virt64/interrupt_gcc.S @@ -114,8 +114,9 @@ trap_entry: /* handle interrupt */ call rt_interrupt_enter csrr a0, SRC_XCAUSE - csrr a1, SRC_XEPC - mv a2, s0 + csrr a1, SRC_XTVAL + csrr a2, SRC_XEPC + mv a3, s0 call handle_trap call rt_interrupt_leave |
