From: Alejandro Colomar Date: Mon, 10 Jun 2024 23:54:22 +0000 (+0200) Subject: ioctl_nsfs.2, NS_GET_NSTYPE.2const: Split NS_GET_NSTYPE from ioctl_nsfs(2) X-Git-Tag: man-pages-6.9~3^2~4^2~4 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=438ca667d80fc4dbc06663a4c8ac37c1afe56dfd;p=thirdparty%2Fman-pages.git ioctl_nsfs.2, NS_GET_NSTYPE.2const: Split NS_GET_NSTYPE from ioctl_nsfs(2) Signed-off-by: Alejandro Colomar --- diff --git a/man/man2/ioctl_nsfs.2 b/man/man2/ioctl_nsfs.2 index f94a7cb03..b1840c840 100644 --- a/man/man2/ioctl_nsfs.2 +++ b/man/man2/ioctl_nsfs.2 @@ -14,34 +14,9 @@ ioctl() operations for Linux namespaces .B NS_GET_USERNS .TQ .B NS_GET_PARENT -.\" ============================================================ -.\" .SS Discovering the namespace type -The +.TP .B NS_GET_NSTYPE -.\" commit e5ff5ce6e20ee22511398bb31fb912466cf82a36 -operation (available since Linux 4.11) can be used to discover -the type of namespace referred to by the file descriptor -.IR fd : -.P -.in +4n -.EX -nstype = ioctl(fd, NS_GET_NSTYPE); -.EE -.in -.P -.I fd -refers to a -.IR /proc/ pid /ns/* -file. -.P -The return value is one of the -.B CLONE_NEW* -values that can be specified to -.BR clone (2) -or -.BR unshare (2) -in order to create a namespace. .\" ============================================================ .\" .SS Discovering the owner of a user namespace @@ -90,6 +65,7 @@ Linux. .BR ioctl (2), .BR NS_GET_USERNS (2const), .BR NS_GET_PARENT (2const), +.BR NS_GET_NSTYPE (2const), .BR fstat (2), .BR proc (5), .BR namespaces (7) diff --git a/man/man2const/NS_GET_NSTYPE.2const b/man/man2const/NS_GET_NSTYPE.2const new file mode 100644 index 000000000..be9378be5 --- /dev/null +++ b/man/man2const/NS_GET_NSTYPE.2const @@ -0,0 +1,40 @@ +.\" Copyright 2017, Michael Kerrisk +.\" +.\" SPDX-License-Identifier: Linux-man-pages-copyleft +.\" +.TH NS_GET_NSTYPE 2const (date) "Linux man-pages (unreleased)" +.SH NAME +NS_GET_NSTYPE +\- +discovering the namespace type +.SH DESCRIPTION +The +.B NS_GET_NSTYPE +.\" commit e5ff5ce6e20ee22511398bb31fb912466cf82a36 +operation (available since Linux 4.11) can be used to discover +the type of namespace referred to by the file descriptor +.IR fd : +.P +.in +4n +.EX +nstype = ioctl(fd, NS_GET_NSTYPE); +.EE +.in +.P +.I fd +refers to a +.IR /proc/ pid /ns/* +file. +.P +The return value is one of the +.B CLONE_NEW* +values that can be specified to +.BR clone (2) +or +.BR unshare (2) +in order to create a namespace. +.SH STANDARDS +Linux. +.SH SEE ALSO +.BR ioctl (2), +.BR ioctl_nsfs (2)