diff options
| author | Sandro Jäckel <sandro.jaeckel@sap.com> | 2022-04-01 14:08:42 +0200 |
|---|---|---|
| committer | Sandro Jäckel <sandro.jaeckel@sap.com> | 2022-04-01 14:09:09 +0200 |
| commit | d35e5fb09bfac1fa381e4ed004ea24a6025e36f4 (patch) | |
| tree | e47874ed2c6830abf4c84e9068bc187fb041b6b4 /vendor/golang.org/x/sys/unix/zptrace_armnn_linux.go | |
| parent | cb398f58a5cb4f3e858fe60e84debde6ab58f7c8 (diff) | |
| download | gofu-d35e5fb09bfac1fa381e4ed004ea24a6025e36f4.tar.gz | |
Bump to go 1.17 and update all dependencies
Diffstat (limited to 'vendor/golang.org/x/sys/unix/zptrace_armnn_linux.go')
| -rw-r--r-- | vendor/golang.org/x/sys/unix/zptrace_armnn_linux.go | 42 |
1 files changed, 42 insertions, 0 deletions
diff --git a/vendor/golang.org/x/sys/unix/zptrace_armnn_linux.go b/vendor/golang.org/x/sys/unix/zptrace_armnn_linux.go new file mode 100644 index 0000000..bd001a6 --- /dev/null +++ b/vendor/golang.org/x/sys/unix/zptrace_armnn_linux.go @@ -0,0 +1,42 @@ +// Code generated by linux/mkall.go generatePtracePair("arm", "arm64"). DO NOT EDIT. + +//go:build linux && (arm || arm64) +// +build linux +// +build arm arm64 + +package unix + +import "unsafe" + +// PtraceRegsArm is the registers used by arm binaries. +type PtraceRegsArm struct { + Uregs [18]uint32 +} + +// PtraceGetRegsArm fetches the registers used by arm binaries. +func PtraceGetRegsArm(pid int, regsout *PtraceRegsArm) error { + return ptrace(PTRACE_GETREGS, pid, 0, uintptr(unsafe.Pointer(regsout))) +} + +// PtraceSetRegsArm sets the registers used by arm binaries. +func PtraceSetRegsArm(pid int, regs *PtraceRegsArm) error { + return ptrace(PTRACE_SETREGS, pid, 0, uintptr(unsafe.Pointer(regs))) +} + +// PtraceRegsArm64 is the registers used by arm64 binaries. +type PtraceRegsArm64 struct { + Regs [31]uint64 + Sp uint64 + Pc uint64 + Pstate uint64 +} + +// PtraceGetRegsArm64 fetches the registers used by arm64 binaries. +func PtraceGetRegsArm64(pid int, regsout *PtraceRegsArm64) error { + return ptrace(PTRACE_GETREGS, pid, 0, uintptr(unsafe.Pointer(regsout))) +} + +// PtraceSetRegsArm64 sets the registers used by arm64 binaries. +func PtraceSetRegsArm64(pid int, regs *PtraceRegsArm64) error { + return ptrace(PTRACE_SETREGS, pid, 0, uintptr(unsafe.Pointer(regs))) +} |
