From 8016cc9034f1ad64fa900cbe8f11974d22989014 Mon Sep 17 00:00:00 2001 From: Eugene Syromyatnikov Date: Wed, 19 Sep 2018 19:12:04 +0200 Subject: [PATCH] clone.2: Add information about clone and clone2 on IA-64 Note that clone() definition on IA-64 is the same as on SH/Tile/Alpha, align __clone2 declarations in line with the previous ones, add clone2 syscall prototype. Signed-off-by: Eugene Syromyatnikov Signed-off-by: Michael Kerrisk --- man2/clone.2 | 31 ++++++++++++++++++------------- 1 file changed, 18 insertions(+), 13 deletions(-) diff --git a/man2/clone.2 b/man2/clone.2 index c7874fa59..6099654ca 100644 --- a/man2/clone.2 +++ b/man2/clone.2 @@ -867,7 +867,7 @@ and there are variations in the arguments across architectures, as detailed in the following paragraphs. .PP The raw system call interface on x86-64 and some other architectures -(including sh, tile, and alpha) is: +(including sh, tile, ia-64, and alpha) is: .PP .in +4 .EX @@ -926,24 +926,29 @@ For details, see the kernel (and glibc) source. .SS ia64 On ia64, a different interface is used: .PP -.nf +.in +4 +.EX .BI "int __clone2(int (*" "fn" ")(void *), " .BI " void *" child_stack_base ", size_t " stack_size , .BI " int " flags ", void *" "arg" ", ... " .BI " /* pid_t *" ptid ", struct user_desc *" tls \ ", pid_t *" ctid " */ );" -.fi +.EE +.in .PP -The prototype shown above is for the glibc wrapper function; -the raw system call interface has no -.I fn -or -.I arg -argument, and changes the order of the arguments so that -.I flags -is the first argument, and -.I tls -is the last argument. +The prototype shown above is for the glibc wrapper function; for the syscall +itself, prototype can be described as follows (it is identical to the +.BR clone () +prototype on microblaze): +.PP +.in +4 +.EX +.BI "long clone2(unsigned long " flags ", void *" child_stack_base , +.BI " int " stack_size , "\fR /* Size of stack */" +.BI " int *" ptid ", int *" ctid , +.BI " unsigned long " tls ); +.EE +.in .PP .BR __clone2 () operates in the same way as