]> git.baikalelectronics.ru Git - kernel.git/commit
unistd: protect clone3 via __ARCH_WANT_SYS_CLONE3
authorChristian Brauner <christian@brauner.io>
Sun, 14 Jul 2019 19:22:05 +0000 (21:22 +0200)
committerChristian Brauner <christian@brauner.io>
Sun, 14 Jul 2019 22:39:48 +0000 (00:39 +0200)
commit7906bd0f3c58457e6405049527eff9a255dc39b0
tree64e9f0f0ba779b4c5d3152beba7df21070775e6d
parentc6fac6d55632a4d2ee10d5f48766580b8efec0a5
unistd: protect clone3 via __ARCH_WANT_SYS_CLONE3

This lets us catch new architectures that implicitly make use of clone3
without setting __ARCH_WANT_SYS_CLONE3.
Failing on missing __ARCH_WANT_SYS_CLONE3 is a good indicator that they
either did not really want this syscall or haven't really thought about
whether it needs special treatment and just accidently included it in
their entrypoints by e.g. generating their syscall table automatically
via asm-generic/unistd.h

This patch has been compile-tested for the h8300 architecture which is
one of the architectures that does not yet implement clone3 and
generates its syscall table via asm-generic/unistd.h.

Signed-off-by: Christian Brauner <christian@brauner.io>
Suggested-by: Arnd Bergmann <arnd@arndb.de>
Link: https://lore.kernel.org/r/20190714192205.27190-3-christian@brauner.io
Reviewed-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Christian Brauner <christian@brauner.io>
include/uapi/asm-generic/unistd.h