summary refs log tree commit diff
path: root/vendor/golang.org/x/sys/unix/zptrace_armnn_linux.go
diff options
context:
space:
mode:
authorEmile <git@emile.space>2024-10-25 15:55:50 +0200
committerEmile <git@emile.space>2024-10-25 15:55:50 +0200
commitc90f36e3dd179d2de96f4f5fe38d8dc9a9de6dfe (patch)
tree89e9afb41c5bf76f48cfb09305a2d3db8d302b06 /vendor/golang.org/x/sys/unix/zptrace_armnn_linux.go
parent98bbb0f559a8883bc47bae80607dbe326a448e61 (diff)
vendor HEAD main
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.go40
1 files changed, 40 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..586317c
--- /dev/null
+++ b/vendor/golang.org/x/sys/unix/zptrace_armnn_linux.go
@@ -0,0 +1,40 @@
+// Code generated by linux/mkall.go generatePtracePair("arm", "arm64"). DO NOT EDIT.
+
+//go:build linux && (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 ptracePtr(PTRACE_GETREGS, pid, 0, unsafe.Pointer(regsout))
+}
+
+// PtraceSetRegsArm sets the registers used by arm binaries.
+func PtraceSetRegsArm(pid int, regs *PtraceRegsArm) error {
+	return ptracePtr(PTRACE_SETREGS, pid, 0, 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 ptracePtr(PTRACE_GETREGS, pid, 0, unsafe.Pointer(regsout))
+}
+
+// PtraceSetRegsArm64 sets the registers used by arm64 binaries.
+func PtraceSetRegsArm64(pid int, regs *PtraceRegsArm64) error {
+	return ptracePtr(PTRACE_SETREGS, pid, 0, unsafe.Pointer(regs))
+}