aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoseph Myers <joseph@codesourcery.com>2021-05-10 20:12:41 +0000
committerJoseph Myers <joseph@codesourcery.com>2021-05-10 20:12:41 +0000
commit3c38f694622cfccd2e922e6e10b5c124c34c1ed0 (patch)
treeb38ec12155a9e0052b35330c337c8eb77e54cca5
parent8d0985b055a83c57785e7cabd4673f75c0bc8fa0 (diff)
downloadglibc-3c38f694622cfccd2e922e6e10b5c124c34c1ed0.zip
glibc-3c38f694622cfccd2e922e6e10b5c124c34c1ed0.tar.gz
glibc-3c38f694622cfccd2e922e6e10b5c124c34c1ed0.tar.bz2
Add PTRACE_SYSEMU and PT_SYSEMU_SINGLESTEP from Linux 5.12 for s390
Linux 5.12 adds the constants PTRACE_SYSEMU and PTRACE_SYSEMU_SINGLESTEP for s390. Add these to glibc. Tested with build-many-glibcs.py for s390-linux-gnu and s390x-linux-gnu.
-rw-r--r--sysdeps/unix/sysv/linux/s390/sys/ptrace.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/sysdeps/unix/sysv/linux/s390/sys/ptrace.h b/sysdeps/unix/sysv/linux/s390/sys/ptrace.h
index 85efbae..4f3c657 100644
--- a/sysdeps/unix/sysv/linux/s390/sys/ptrace.h
+++ b/sysdeps/unix/sysv/linux/s390/sys/ptrace.h
@@ -39,6 +39,8 @@ __BEGIN_DECLS
# undef PTRACE_ATTACH
# undef PTRACE_DETACH
# undef PTRACE_SYSCALL
+# undef PTRACE_SYSEMU
+# undef PTRACE_SYSEMU_SINGLESTEP
# undef PTRACE_SETOPTIONS
# undef PTRACE_GETEVENTMSG
# undef PTRACE_GETSIGINFO
@@ -146,6 +148,14 @@ enum __ptrace_request
PTRACE_SYSCALL = 24,
#define PT_SYSCALL PTRACE_SYSCALL
+ /* Continue and stop at the next syscall, it will not be executed. */
+ PTRACE_SYSEMU = 31,
+#define PT_SYSEMU PTRACE_SYSEMU
+
+ /* Single step the process, the next syscall will not be executed. */
+ PTRACE_SYSEMU_SINGLESTEP = 32,
+#define PT_SYSEMU_SINGLESTEP PTRACE_SYSEMU_SINGLESTEP
+
/* Set ptrace filter options. */
PTRACE_SETOPTIONS = 0x4200,
#define PT_SETOPTIONS PTRACE_SETOPTIONS