arch: wire-up clone3() syscall
authorChristian Brauner <christian@brauner.io>
Sat, 25 May 2019 09:37:43 +0000 (11:37 +0200)
committerChristian Brauner <christian@brauner.io>
Sun, 9 Jun 2019 07:29:46 +0000 (09:29 +0200)
Wire up the clone3() call on all arches that don't require hand-rolled
assembly.

Some of the arches look like they need special assembly massaging and it is
probably smarter if the appropriate arch maintainers would do the actual
wiring. Arches that are wired-up are:
- x86{_32,64}
- arm{64}
- xtensa

Signed-off-by: Christian Brauner <christian@brauner.io>
Acked-by: Arnd Bergmann <arnd@arndb.de>
Cc: Kees Cook <keescook@chromium.org>
Cc: David Howells <dhowells@redhat.com>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Oleg Nesterov <oleg@redhat.com>
Cc: Adrian Reber <adrian@lisas.de>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Al Viro <viro@zeniv.linux.org.uk>
Cc: Florian Weimer <fweimer@redhat.com>
Cc: linux-api@vger.kernel.org
Cc: linux-arch@vger.kernel.org
Cc: x86@kernel.org
arch/arm/tools/syscall.tbl
arch/arm64/include/asm/unistd.h
arch/arm64/include/asm/unistd32.h
arch/microblaze/kernel/syscalls/syscall.tbl
arch/x86/entry/syscalls/syscall_32.tbl
arch/x86/entry/syscalls/syscall_64.tbl
arch/xtensa/kernel/syscalls/syscall.tbl
include/uapi/asm-generic/unistd.h

index aaf479a..e99a82b 100644 (file)
 431    common  fsconfig                        sys_fsconfig
 432    common  fsmount                         sys_fsmount
 433    common  fspick                          sys_fspick
+436    common  clone3                          sys_clone3
index 70e6882..24480c2 100644 (file)
@@ -44,7 +44,7 @@
 #define __ARM_NR_compat_set_tls                (__ARM_NR_COMPAT_BASE + 5)
 #define __ARM_NR_COMPAT_END            (__ARM_NR_COMPAT_BASE + 0x800)
 
-#define __NR_compat_syscalls           434
+#define __NR_compat_syscalls           437
 #endif
 
 #define __ARCH_WANT_SYS_CLONE
index c39e906..b144ea6 100644 (file)
@@ -886,6 +886,8 @@ __SYSCALL(__NR_fsconfig, sys_fsconfig)
 __SYSCALL(__NR_fsmount, sys_fsmount)
 #define __NR_fspick 433
 __SYSCALL(__NR_fspick, sys_fspick)
+#define __NR_clone3 436
+__SYSCALL(__NR_clone3, sys_clone3)
 
 /*
  * Please add new compat syscalls above this comment and update
index 26339e4..3110440 100644 (file)
 431    common  fsconfig                        sys_fsconfig
 432    common  fsmount                         sys_fsmount
 433    common  fspick                          sys_fspick
+436    common  clone3                          sys_clone3
index ad968b7..80e2621 100644 (file)
 431    i386    fsconfig                sys_fsconfig                    __ia32_sys_fsconfig
 432    i386    fsmount                 sys_fsmount                     __ia32_sys_fsmount
 433    i386    fspick                  sys_fspick                      __ia32_sys_fspick
+436    i386    clone3                  sys_clone3                      __ia32_sys_clone3
index b4e6f9e..7968f0b 100644 (file)
 431    common  fsconfig                __x64_sys_fsconfig
 432    common  fsmount                 __x64_sys_fsmount
 433    common  fspick                  __x64_sys_fspick
+436    common  clone3                  __x64_sys_clone3/ptregs
 
 #
 # x32-specific system call numbers start at 512 to avoid cache impact
index 5fa0ee1..b2767c8 100644 (file)
 431    common  fsconfig                        sys_fsconfig
 432    common  fsmount                         sys_fsmount
 433    common  fspick                          sys_fspick
+436    common  clone3                          sys_clone3
index a87904d..45bc876 100644 (file)
@@ -844,9 +844,11 @@ __SYSCALL(__NR_fsconfig, sys_fsconfig)
 __SYSCALL(__NR_fsmount, sys_fsmount)
 #define __NR_fspick 433
 __SYSCALL(__NR_fspick, sys_fspick)
+#define __NR_clone3 436
+__SYSCALL(__NR_clone3, sys_clone3)
 
 #undef __NR_syscalls
-#define __NR_syscalls 434
+#define __NR_syscalls 437
 
 /*
  * 32 bit systems traditionally used different