...
Source file src/pkg/cmd/vendor/golang.org/x/sys/unix/zptracearm_linux.go
1
2
3
4
5
6 package unix
7
8 import "unsafe"
9
10
11 type PtraceRegsArm struct {
12 Uregs [18]uint32
13 }
14
15
16 func PtraceGetRegsArm(pid int, regsout *PtraceRegsArm) error {
17 return ptrace(PTRACE_GETREGS, pid, 0, uintptr(unsafe.Pointer(regsout)))
18 }
19
20
21 func PtraceSetRegsArm(pid int, regs *PtraceRegsArm) error {
22 return ptrace(PTRACE_SETREGS, pid, 0, uintptr(unsafe.Pointer(regs)))
23 }
24
25
26 type PtraceRegsArm64 struct {
27 Regs [31]uint64
28 Sp uint64
29 Pc uint64
30 Pstate uint64
31 }
32
33
34 func PtraceGetRegsArm64(pid int, regsout *PtraceRegsArm64) error {
35 return ptrace(PTRACE_GETREGS, pid, 0, uintptr(unsafe.Pointer(regsout)))
36 }
37
38
39 func PtraceSetRegsArm64(pid int, regs *PtraceRegsArm64) error {
40 return ptrace(PTRACE_SETREGS, pid, 0, uintptr(unsafe.Pointer(regs)))
41 }
42
View as plain text