aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/tools/testing/selftests/vm
diff options
context:
space:
mode:
authorKees Cook <keescook@chromium.org>2022-03-24 18:14:18 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2022-03-24 19:06:51 -0700
commit25fd2d41b505d0640bdfe67aa77c549de2d3c18a (patch)
treead95618faec3f5e14cd5e4ff5805d4a1fbf3abe2 /tools/testing/selftests/vm
parentmm: madvise: MADV_DONTNEED_LOCKED (diff)
downloadwireguard-linux-25fd2d41b505d0640bdfe67aa77c549de2d3c18a.tar.xz
wireguard-linux-25fd2d41b505d0640bdfe67aa77c549de2d3c18a.zip
selftests: kselftest framework: provide "finished" helper
Instead of having each time that wants to use ksft_exit() have to figure out the internals of kselftest.h, add the helper ksft_finished() that makes sure the passes, xfails, and skips are equal to the test plan count. Link: https://lkml.kernel.org/r/20220201013717.2464392-1-keescook@chromium.org Signed-off-by: Kees Cook <keescook@chromium.org> Cc: Shuah Khan <shuah@kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'tools/testing/selftests/vm')
-rw-r--r--tools/testing/selftests/vm/memfd_secret.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/testing/selftests/vm/memfd_secret.c b/tools/testing/selftests/vm/memfd_secret.c
index 93e7e7ffed33..957b9e18c729 100644
--- a/tools/testing/selftests/vm/memfd_secret.c
+++ b/tools/testing/selftests/vm/memfd_secret.c
@@ -282,7 +282,7 @@ int main(int argc, char *argv[])
close(fd);
- ksft_exit(!ksft_get_fail_cnt());
+ ksft_finished();
}
#else /* __NR_memfd_secret */