set architecture riscv:rv64 -- fix gdb trampoline disassembly, thanks jonathan
This commit is contained in:
parent
35010f0d0f
commit
036b5edf12
|
@ -1,5 +1,5 @@
|
|||
set confirm off
|
||||
set architecture riscv
|
||||
set architecture riscv:rv64
|
||||
target remote 127.0.0.1:1234
|
||||
symbol-file kernel/kernel
|
||||
set disassemble-next-line auto
|
||||
|
|
|
@ -70,7 +70,7 @@ uservec:
|
|||
# make tp hold the current hartid, from p->tf->kernel_hartid
|
||||
ld tp, 32(a0)
|
||||
|
||||
# remember the address of usertrap(), p->tf->kernel_trap
|
||||
# load the address of usertrap(), p->tf->kernel_trap
|
||||
ld t0, 16(a0)
|
||||
|
||||
# restore kernel page table from p->tf->kernel_satp
|
||||
|
@ -79,7 +79,7 @@ uservec:
|
|||
sfence.vma zero, zero
|
||||
|
||||
# a0 is no longer valid, since the kernel page
|
||||
# table does not specially map p->td.
|
||||
# table does not specially map p->tf.
|
||||
|
||||
# jump to usertrap(), which does not return
|
||||
jr t0
|
||||
|
@ -89,8 +89,8 @@ userret:
|
|||
# userret(TRAPFRAME, pagetable)
|
||||
# switch from kernel to user.
|
||||
# usertrapret() calls here.
|
||||
# a0: TRAPFRAME, in user page table
|
||||
# a1: user page table, for satp
|
||||
# a0: TRAPFRAME, in user page table.
|
||||
# a1: user page table, for satp.
|
||||
|
||||
# switch to the user page table.
|
||||
csrw satp, a1
|
||||
|
|
Loading…
Reference in a new issue