[PATCH v3 2/2] manual: add architecture specific note on clone and clone3 syscalls

Yury Khrustalev yury.khrustalev@arm.com
Fri Jun 20 13:20:41 GMT 2025


Add a new section for architecture specific notes for syscalls.

Add a note about calling the __arm_za_disable() function when the
clone and clone3 syscalls are invoked directly via the syscall()
function rather than using Glibc wrapper.
---
 manual/startup.texi | 13 +++++++++++++
 1 file changed, 13 insertions(+)

diff --git a/manual/startup.texi b/manual/startup.texi
index 6f29ddd8cf..8bfbafaa8d 100644
--- a/manual/startup.texi
+++ b/manual/startup.texi
@@ -804,6 +804,19 @@ if (rc == -1)
 
 @end deftypefun
 
+@subsection Architecture specific notes on system calls
+
+Because @code{syscall} function does not know anything about what a particular
+system call does or what are the ABI requirements for it, it is important to be
+aware of any additional requirements that target kernel might have for certain
+system calls.
+
+On AArch64 systems with enabled SME extension, system calls with @var{sysno}
+equal to @code{SYS_clone} or @code{SYS_clone3} must be preceded with a call
+to the @code{__arm_za_disable()} function in order to disable ZA state of SME
+(see @url{https://github.com/ARM-software/abi-aa/blob/main/aapcs64/aapcs64.rst}
+for details) . When the @code{clone()} wrapper provided by @theglibc{} is use,
+this would happen automatically.
 
 @node Program Termination
 @section Program Termination
-- 
2.39.5



More information about the Libc-alpha mailing list