kselftest/seccomp: Use kselftest output functions for benchmark
authorMark Brown <broonie@kernel.org>
Wed, 24 Jan 2024 13:00:18 +0000 (13:00 +0000)
committerShuah Khan <skhan@linuxfoundation.org>
Tue, 30 Jan 2024 15:55:42 +0000 (08:55 -0700)
commit5820cfee443f8a90ea3eb9f99f57f2049a4a93c3
treec3e83362566a18c571a3855effcb32ccf028f04d
parentf1fea725cc93fcc3c5af9a2af63ffdc40dd2259e
kselftest/seccomp: Use kselftest output functions for benchmark

In preparation for trying to output the test results themselves in TAP
format rework all the prints in the benchmark to use the kselftest output
functions. The uses of system() all produce single line output so we can
avoid having to deal with fully managing the child process and continue to
use system() by simply printing an empty message before we invoke system().
We also leave one printf() used to complete a line of output in place.

Tested-by: Anders Roxell <anders.roxell@linaro.org>
Acked-by: Kees Cook <keescook@chromium.org>
Signed-off-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
tools/testing/selftests/seccomp/seccomp_benchmark.c