summaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorTobias Klauser <tklauser@distanz.ch>2023-03-08 13:53:20 +0300
committerChristian Brauner (Microsoft) <brauner@kernel.org>2023-03-08 14:31:35 +0300
commit515bddf0ec4155cbd666d72daf5bd68c8b7cd987 (patch)
tree28875e41eddcdad763103903e46760b7ef354a3d /tools
parenta402f1e35313fc7ce2ca60f543c4402c2c7c3544 (diff)
downloadlinux-515bddf0ec4155cbd666d72daf5bd68c8b7cd987.tar.xz
selftests/clone3: test clone3 with CLONE_NEWTIME
Verify that clone3 can be called successfully with CLONE_NEWTIME in flags. Cc: Andrey Vagin <avagin@openvz.org> Cc: Christian Brauner <brauner@kernel.org> Cc: Shuah Khan <shuah@kernel.org> Signed-off-by: Tobias Klauser <tklauser@distanz.ch> Signed-off-by: Christian Brauner (Microsoft) <brauner@kernel.org>
Diffstat (limited to 'tools')
-rw-r--r--tools/testing/selftests/clone3/clone3.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/tools/testing/selftests/clone3/clone3.c b/tools/testing/selftests/clone3/clone3.c
index cd4582129c7d..4fce46afe6db 100644
--- a/tools/testing/selftests/clone3/clone3.c
+++ b/tools/testing/selftests/clone3/clone3.c
@@ -195,5 +195,8 @@ int main(int argc, char *argv[])
test_clone3(CLONE_NEWPID, getpagesize() + 8, -E2BIG,
CLONE3_ARGS_NO_TEST);
+ /* Do a clone3() in a new time namespace */
+ test_clone3(CLONE_NEWTIME, 0, 0, CLONE3_ARGS_NO_TEST);
+
return !ksft_get_fail_cnt() ? ksft_exit_pass() : ksft_exit_fail();
}