The testing script recommends CONFIG_TEST_SYSCTL=y, but actually only works with CONFIG_TEST_SYSCTL=m. Testing of sysctl setting via boot param however requires the test to be built-in, so make sure the test script supports it. Signed-off-by: Vlastimil Babka <vbabka@xxxxxxx> --- tools/testing/selftests/sysctl/sysctl.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tools/testing/selftests/sysctl/sysctl.sh b/tools/testing/selftests/sysctl/sysctl.sh index 6a970b127c9b..ce1eeea6f769 100755 --- a/tools/testing/selftests/sysctl/sysctl.sh +++ b/tools/testing/selftests/sysctl/sysctl.sh @@ -42,7 +42,7 @@ ALL_TESTS="$ALL_TESTS 0006:50:1:bitmap_0001" test_modprobe() { - if [ ! -d $DIR ]; then + if [ ! -d $SYSCTL ]; then echo "$0: $DIR not present" >&2 echo "You must have the following enabled in your kernel:" >&2 cat $TEST_DIR/config >&2 @@ -122,9 +122,9 @@ test_reqs() function load_req_mod() { - if [ ! -d $DIR ]; then + if [ ! -d $DIR -a ! -d $SYSCTL ]; then if ! modprobe -q -n $TEST_DRIVER; then - echo "$0: module $TEST_DRIVER not found [SKIP]" + echo "$0: module $TEST_DRIVER not found and not built-in [SKIP]" exit $ksft_skip fi modprobe $TEST_DRIVER -- 2.26.0