diff options
author | Rae Moar <rmoar@google.com> | 2023-12-13 19:44:20 +0000 |
---|---|---|
committer | Shuah Khan <skhan@linuxfoundation.org> | 2023-12-18 13:25:49 -0700 |
commit | c72a870926c2de694942aaac2b49e59ce789bb74 (patch) | |
tree | ff305514a572da68cf480082dfe0167dc4bd1e40 /scripts/gcc-plugins/randomize_layout_plugin.c | |
parent | 6c4ea2f48de9860217ddfedee081d485dbeea7e8 (diff) |
kunit: add ability to run tests after boot using debugfs
Add functionality to run built-in tests after boot by writing to a
debugfs file.
Add a new debugfs file labeled "run" for each test suite to use for
this purpose.
As an example, write to the file using the following:
echo "any string" > /sys/kernel/debugfs/kunit/<testsuite>/run
This will trigger the test suite to run and will print results to the
kernel log.
To guard against running tests concurrently with this feature, add a
mutex lock around running kunit. This supports the current practice of
not allowing tests to be run concurrently on the same kernel.
This new functionality could be used to design a parameter
injection feature in the future.
Fixed up merge conflict duing rebase to Linux 6.7-rc6
Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
Reviewed-by: David Gow <davidgow@google.com>
Signed-off-by: Rae Moar <rmoar@google.com>
Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
Diffstat (limited to 'scripts/gcc-plugins/randomize_layout_plugin.c')
0 files changed, 0 insertions, 0 deletions