Skip to content

Commit 6fed506

Browse files
committed
Auto merge of #2814 - lattice0:feature-android-sys-prctl.h, r=JohnTitor
adds android sys/prctl.h adds some sys/prctl.h symbols to Android, checked against the NDK .h file for validity of numbers. These are needed for making [firecracker](https://github.com/firecracker-microvm/firecracker/blob/6b4a4b1c0490e006e02db7579831cbf14e05abae/src/seccompiler/src/backend.rs#L943) work on Android hosts
2 parents 99756b1 + afad558 commit 6fed506

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

libc-test/semver/android.txt

+4
Original file line numberDiff line numberDiff line change
@@ -1638,6 +1638,10 @@ POSIX_FADV_SEQUENTIAL
16381638
POSIX_FADV_WILLNEED
16391639
PR_SET_VMA
16401640
PR_SET_VMA_ANON_NAME
1641+
PR_SET_NO_NEW_PRIVS
1642+
PR_GET_NO_NEW_PRIVS
1643+
PR_GET_SECCOMP
1644+
PR_SET_SECCOMP
16411645
PRIO_MAX
16421646
PRIO_MIN
16431647
PRIO_PGRP

src/unix/linux_like/android/mod.rs

+4
Original file line numberDiff line numberDiff line change
@@ -2498,6 +2498,10 @@ pub const PROP_NAME_MAX: ::c_int = 32;
24982498
// sys/prctl.h
24992499
pub const PR_SET_VMA: ::c_int = 0x53564d41;
25002500
pub const PR_SET_VMA_ANON_NAME: ::c_int = 0;
2501+
pub const PR_SET_NO_NEW_PRIVS: ::c_int = 38;
2502+
pub const PR_GET_NO_NEW_PRIVS: ::c_int = 39;
2503+
pub const PR_GET_SECCOMP: ::c_int = 21;
2504+
pub const PR_SET_SECCOMP: ::c_int = 22;
25012505

25022506
f! {
25032507
pub fn CMSG_NXTHDR(mhdr: *const msghdr,

0 commit comments

Comments
 (0)