Patch "selftests/clone3: fix number of tests in ksft_set_plan" has been added to the 6.3-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    selftests/clone3: fix number of tests in ksft_set_plan

to the 6.3-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     selftests-clone3-fix-number-of-tests-in-ksft_set_pla.patch
and it can be found in the queue-6.3 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit c9a9d11b421b8c5c750031cb3a0b2ff8badaca7e
Author: Tobias Klauser <tklauser@xxxxxxxxxx>
Date:   Tue Mar 14 13:34:14 2023 +0100

    selftests/clone3: fix number of tests in ksft_set_plan
    
    [ Upstream commit d95debbdc528d50042807754d6085c15abc21768 ]
    
    Commit 515bddf0ec41 ("selftests/clone3: test clone3 with CLONE_NEWTIME")
    added an additional test, so the number passed to ksft_set_plan needs to
    be bumped accordingly.
    
    Also use ksft_finished() to print results and exit. This will catch future
    mismatches between ksft_set_plan() and the number of tests being run.
    
    Fixes: 515bddf0ec41 ("selftests/clone3: test clone3 with CLONE_NEWTIME")
    Cc: Christian Brauner <brauner@xxxxxxxxxx>
    Signed-off-by: Tobias Klauser <tklauser@xxxxxxxxxx>
    Reviewed-by: Christian Brauner <brauner@xxxxxxxxxx>
    Signed-off-by: Christian Brauner <brauner@xxxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/tools/testing/selftests/clone3/clone3.c b/tools/testing/selftests/clone3/clone3.c
index 4fce46afe6db8..e495f895a2cdd 100644
--- a/tools/testing/selftests/clone3/clone3.c
+++ b/tools/testing/selftests/clone3/clone3.c
@@ -129,7 +129,7 @@ int main(int argc, char *argv[])
 	uid_t uid = getuid();
 
 	ksft_print_header();
-	ksft_set_plan(17);
+	ksft_set_plan(18);
 	test_clone3_supported();
 
 	/* Just a simple clone3() should return 0.*/
@@ -198,5 +198,5 @@ int main(int argc, char *argv[])
 	/* 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();
+	ksft_finished();
 }



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux