1 /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ 2 3 #ifndef _UAPI_LINUX_PIDFD_H 4 #define _UAPI_LINUX_PIDFD_H 5 6 #include <linux/types.h> 7 #include <linux/fcntl.h> 8 #include <linux/ioctl.h> 9 10 /* Flags for pidfd_open(). */ 11 #define PIDFD_NONBLOCK O_NONBLOCK 12 #define PIDFD_THREAD O_EXCL 13 14 /* Flags for pidfd_send_signal(). */ 15 #define PIDFD_SIGNAL_THREAD (1UL << 0) 16 #define PIDFD_SIGNAL_THREAD_GROUP (1UL << 1) 17 #define PIDFD_SIGNAL_PROCESS_GROUP (1UL << 2) 18 19 #define PIDFS_IOCTL_MAGIC 0xFF 20 21 #define PIDFD_GET_CGROUP_NAMESPACE _IO(PIDFS_IOCTL_MAGIC, 1) 22 #define PIDFD_GET_IPC_NAMESPACE _IO(PIDFS_IOCTL_MAGIC, 2) 23 #define PIDFD_GET_MNT_NAMESPACE _IO(PIDFS_IOCTL_MAGIC, 3) 24 #define PIDFD_GET_NET_NAMESPACE _IO(PIDFS_IOCTL_MAGIC, 4) 25 #define PIDFD_GET_PID_NAMESPACE _IO(PIDFS_IOCTL_MAGIC, 5) 26 #define PIDFD_GET_PID_FOR_CHILDREN_NAMESPACE _IO(PIDFS_IOCTL_MAGIC, 6) 27 #define PIDFD_GET_TIME_NAMESPACE _IO(PIDFS_IOCTL_MAGIC, 7) 28 #define PIDFD_GET_TIME_FOR_CHILDREN_NAMESPACE _IO(PIDFS_IOCTL_MAGIC, 8) 29 #define PIDFD_GET_USER_NAMESPACE _IO(PIDFS_IOCTL_MAGIC, 9) 30 #define PIDFD_GET_UTS_NAMESPACE _IO(PIDFS_IOCTL_MAGIC, 10) 31 32 #endif /* _UAPI_LINUX_PIDFD_H */ 33