diff options
author | David Carlier <devnexen@gmail.com> | 2022-09-25 00:17:29 +0100 |
---|---|---|
committer | David Carlier <devnexen@gmail.com> | 2022-09-29 19:45:32 +0100 |
commit | 2bd3e499a79afa9b786d9859c5dfb4446ae22286 (patch) | |
tree | 6460604605d8a41dd0e4a484026fdf396095f975 | |
parent | 362960cecb52eb87fb07d022f6b0fe3b257c0592 (diff) | |
download | rust-libc-2bd3e499a79afa9b786d9859c5dfb4446ae22286.tar.gz |
linux add ptrace_rseq_configuration
-rw-r--r-- | libc-test/build.rs | 3 | ||||
-rw-r--r-- | libc-test/semver/linux-gnu-x86_64.txt | 2 | ||||
-rw-r--r-- | src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs | 9 |
3 files changed, 14 insertions, 0 deletions
diff --git a/libc-test/build.rs b/libc-test/build.rs index d1718454e4..0e56050b00 100644 --- a/libc-test/build.rs +++ b/libc-test/build.rs @@ -3068,6 +3068,7 @@ fn test_linux(target: &str) { // FIXME: Unignore once we update Ubuntu to 22.04 "mallinfo2" if sparc64 => true, + "ptrace_rseq_configuration" if sparc64 => true, _ => false, } @@ -3309,6 +3310,8 @@ fn test_linux(target: &str) { | "IFLA_PERM_ADDRESS" | "IFLA_PROTO_DOWN_REASON" if sparc64 => true, + // Added in Linux 5.13 + "PTRACE_GET_RSEQ_CONFIGURATION" if sparc64 => true, _ => false, } diff --git a/libc-test/semver/linux-gnu-x86_64.txt b/libc-test/semver/linux-gnu-x86_64.txt index dfe109307f..604f7d845e 100644 --- a/libc-test/semver/linux-gnu-x86_64.txt +++ b/libc-test/semver/linux-gnu-x86_64.txt @@ -19,12 +19,14 @@ NFT_MSG_NEWOBJ PTHREAD_ADAPTIVE_MUTEX_INITIALIZER_NP PTHREAD_ERRORCHECK_MUTEX_INITIALIZER_NP PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP +PTRACE_GET_RSEQ_CONFIGURATION PTRACE_SYSEMU PTRACE_SYSEMU_SINGLESTEP _libc_fpstate flock64 getcontext makecontext +ptrace_rseq_configuration setcontext swapcontext termios2 diff --git a/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs b/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs index 7e876f2d86..d515d22315 100644 --- a/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs +++ b/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs @@ -265,6 +265,14 @@ s! { pub seccomp_notif_resp: ::__u16, pub seccomp_data: ::__u16, } + + pub struct ptrace_rseq_configuration { + pub rseq_abi_pointer: ::__u64, + pub rseq_abi_size: ::__u32, + pub signature: ::__u32, + pub flags: ::__u32, + pub pad: ::__u32, + } } s_no_extra_traits! { @@ -535,6 +543,7 @@ pub const O_ASYNC: ::c_int = 0x2000; pub const O_NDELAY: ::c_int = 0x800; pub const PTRACE_DETACH: ::c_uint = 17; +pub const PTRACE_GET_RSEQ_CONFIGURATION: ::c_uint = 0x420f; pub const EFD_NONBLOCK: ::c_int = 0x800; |