Thread (2 messages) 2 messages, 2 authors, 2025-12-17

[PATCH] man/man2/clone.2: Document E2BIG-based extension handshake

From: Florian Weimer <hidden>
Date: 2025-12-15 10:34:38
Subsystem: the rest · Maintainer: Linus Torvalds

The clone3 system call uses copy_struct_from_user and the E2BIG
error code to handle changes to the struct clone_args size.

Signed-off-by: Florian Weimer <redacted>

---
 man/man2/clone.2 | 10 ++++++++++
 1 file changed, 10 insertions(+)
diff --git a/man/man2/clone.2 b/man/man2/clone.2
index 74c5a59be..1d62a5df1 100644
--- a/man/man2/clone.2
+++ b/man/man2/clone.2
@@ -1188,6 +1188,16 @@ in the caller's context, no child process is created, and
 is set to indicate the error.
 .SH ERRORS
 .TP
+.BR E2BIG " (" clone3 "() only)"
+The kernel does not support some functionality requested in this
+.BR clone3 ()
+call:
+The size argument is larger than what the kernel supports,
+and there are non-zero values in the struct after the kernel-supported size.
+.TP
+.BR E2BIG " (" clone3 "() only)"
+The size argument is larger than the page size.
+.TP
 .BR EACCES " (" clone3 "() only)"
 .B CLONE_INTO_CGROUP
 was specified in
base-commit: 46950a0845de91c422efe6c639091ace42cb92f8
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help