1
0
Fork 0

selftests: Install settings files to fix TIMEOUT failures

commit b9167c8078 upstream.

Commit 852c8cbf34 ("selftests/kselftest/runner.sh: Add 45 second
timeout per test") added a 45 second timeout for tests, and also added
a way for tests to customise the timeout via a settings file.

For example the ftrace tests take multiple minutes to run, so they
were given longer in commit b43e78f65b ("tracing/selftests: Turn off
timeout setting").

This works when the tests are run from the source tree. However if the
tests are installed with "make -C tools/testing/selftests install",
the settings files are not copied into the install directory. When the
tests are then run from the install directory the longer timeouts are
not applied and the tests timeout incorrectly.

So add the settings files to TEST_FILES of the appropriate Makefiles
to cause the settings files to be installed using the existing install
logic.

Fixes: 852c8cbf34 ("selftests/kselftest/runner.sh: Add 45 second timeout per test")
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
5.4-rM2-2.2.x-imx-squashed
Michael Ellerman 2020-02-20 15:42:41 +11:00 committed by Greg Kroah-Hartman
parent 483724e27e
commit 20e559d8f7
4 changed files with 7 additions and 1 deletions

View File

@ -2,7 +2,7 @@
all:
TEST_PROGS := ftracetest
TEST_FILES := test.d
TEST_FILES := test.d settings
EXTRA_CLEAN := $(OUTPUT)/logs/*
include ../lib.mk

View File

@ -6,4 +6,6 @@ TEST_PROGS := \
test-callbacks.sh \
test-shadow-vars.sh
TEST_FILES := settings
include ../lib.mk

View File

@ -19,6 +19,8 @@ TEST_GEN_PROGS_EXTENDED = librseq.so
TEST_PROGS = run_param_test.sh
TEST_FILES := settings
include ../lib.mk
$(OUTPUT)/librseq.so: rseq.c rseq.h rseq-*.h

View File

@ -6,4 +6,6 @@ TEST_GEN_PROGS = rtctest
TEST_GEN_PROGS_EXTENDED = setdate
TEST_FILES := settings
include ../lib.mk