From 76cb841cb886eef6b3bee341a2266c76578724ad Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Mon, 6 May 2024 03:02:30 +0200 Subject: Adding upstream version 4.19.249. Signed-off-by: Daniel Baumann --- tools/testing/selftests/lib/printf.sh | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100755 tools/testing/selftests/lib/printf.sh (limited to 'tools/testing/selftests/lib/printf.sh') diff --git a/tools/testing/selftests/lib/printf.sh b/tools/testing/selftests/lib/printf.sh new file mode 100755 index 000000000..45a23e2d6 --- /dev/null +++ b/tools/testing/selftests/lib/printf.sh @@ -0,0 +1,19 @@ +#!/bin/sh +# SPDX-License-Identifier: GPL-2.0 +# Runs printf infrastructure using test_printf kernel module + +# Kselftest framework requirement - SKIP code is 4. +ksft_skip=4 + +if ! /sbin/modprobe -q -n test_printf; then + echo "printf: module test_printf is not found [SKIP]" + exit $ksft_skip +fi + +if /sbin/modprobe -q test_printf; then + /sbin/modprobe -q -r test_printf + echo "printf: ok" +else + echo "printf: [FAIL]" + exit 1 +fi -- cgit v1.2.3