From: Kir Kolyshkin <kolyshkin@gmail.com>
To: Alejandro Colomar <alx@kernel.org>
Cc: Kir Kolyshkin <kolyshkin@gmail.com>,
linux-man@vger.kernel.org, Christian Brauner <brauner@kernel.org>,
Oleg Nesterov <oleg@redhat.com>
Subject: [PATCH 1/3] clone.2: document CLONE_PIDFD | CLONE_THREAD
Date: Tue, 7 Oct 2025 19:00:28 -0700 [thread overview]
Message-ID: <20251008020031.1215030-2-kolyshkin@gmail.com> (raw)
In-Reply-To: <20251008020031.1215030-1-kolyshkin@gmail.com>
Available since Linux 6.9 [1]. Documented in [2] (added by [3]).
[1]: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=83b290c9e3b5d95891f
[2]: https://github.com/brauner/man-pages-md/blob/main/clone.md
[3]: https://github.com/brauner/man-pages-md/pull/4
Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
---
man/man2/clone.2 | 22 ++++++++++------------
1 file changed, 10 insertions(+), 12 deletions(-)
diff --git a/man/man2/clone.2 b/man/man2/clone.2
index 68f86a934..edccde742 100644
--- a/man/man2/clone.2
+++ b/man/man2/clone.2
@@ -864,10 +864,16 @@ .SS The flags mask
.BR clone ().
.RE
.IP
-It is currently not possible to use this flag together with
-.B CLONE_THREAD.
-This means that the process identified by the PID file descriptor
-will always be a thread group leader.
+If
+.B CLONE_PIDFD
+is specified together with
+.BR CLONE_THREAD ,
+the obtained PID file descriptor refers to a specific thread,
+as opposed to a thread-group leader if
+.B CLONE_THREAD
+is not specified.
+This feature is available since Linux 6.9.
+.\" commit 83b290c9e3b5d95891f43a4aeadf6071cbff25d3
.IP
If the obsolete
.B CLONE_DETACHED
@@ -1386,14 +1392,6 @@ .SH ERRORS
.I flags
mask.
.TP
-.B EINVAL
-.B CLONE_PIDFD
-was specified together with
-.B CLONE_THREAD
-in the
-.I flags
-mask.
-.TP
.BR "EINVAL " "(" clone "() only)"
.B CLONE_PIDFD
was specified together with
--
2.51.0
next prev parent reply other threads:[~2025-10-08 2:00 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-10-08 2:00 [PATCH v2 0/3] man2: document Linux v6.9 pidfd-related changes Kir Kolyshkin
2025-10-08 2:00 ` Kir Kolyshkin [this message]
2025-10-12 21:35 ` [PATCH 1/3] clone.2: document CLONE_PIDFD | CLONE_THREAD Alejandro Colomar
2025-10-08 2:00 ` [PATCH v2 2/3] pidfd_open.2: add PIDFD_THREAD Kir Kolyshkin
2025-10-12 22:16 ` Alejandro Colomar
2025-10-13 19:10 ` [PATCH v3 " Kir Kolyshkin
2025-10-15 21:16 ` Alejandro Colomar
2025-10-16 0:06 ` Kirill Kolyshkin
2025-10-16 10:33 ` Alejandro Colomar
2025-10-29 10:28 ` Alejandro Colomar
2025-10-08 2:00 ` [PATCH 3/3] pidfd_send_signal.2: describe flags Kir Kolyshkin
2025-10-29 11:14 ` Alejandro Colomar
-- strict thread matches above, loose matches on Subject: below --
2024-07-09 2:13 [PATCH 0/3] man2: document Linux v6.9 pidfd-related changes Kir Kolyshkin
2024-07-09 2:13 ` [PATCH 1/3] clone.2: document CLONE_PIDFD | CLONE_THREAD Kir Kolyshkin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20251008020031.1215030-2-kolyshkin@gmail.com \
--to=kolyshkin@gmail.com \
--cc=alx@kernel.org \
--cc=brauner@kernel.org \
--cc=linux-man@vger.kernel.org \
--cc=oleg@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox