xref: /OK3568_Linux_fs/kernel/include/uapi/linux/nsfs.h (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1*4882a593Smuzhiyun /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */
2*4882a593Smuzhiyun #ifndef __LINUX_NSFS_H
3*4882a593Smuzhiyun #define __LINUX_NSFS_H
4*4882a593Smuzhiyun 
5*4882a593Smuzhiyun #include <linux/ioctl.h>
6*4882a593Smuzhiyun 
7*4882a593Smuzhiyun #define NSIO	0xb7
8*4882a593Smuzhiyun 
9*4882a593Smuzhiyun /* Returns a file descriptor that refers to an owning user namespace */
10*4882a593Smuzhiyun #define NS_GET_USERNS		_IO(NSIO, 0x1)
11*4882a593Smuzhiyun /* Returns a file descriptor that refers to a parent namespace */
12*4882a593Smuzhiyun #define NS_GET_PARENT		_IO(NSIO, 0x2)
13*4882a593Smuzhiyun /* Returns the type of namespace (CLONE_NEW* value) referred to by
14*4882a593Smuzhiyun    file descriptor */
15*4882a593Smuzhiyun #define NS_GET_NSTYPE		_IO(NSIO, 0x3)
16*4882a593Smuzhiyun /* Get owner UID (in the caller's user namespace) for a user namespace */
17*4882a593Smuzhiyun #define NS_GET_OWNER_UID	_IO(NSIO, 0x4)
18*4882a593Smuzhiyun 
19*4882a593Smuzhiyun #endif /* __LINUX_NSFS_H */
20