From: Masami Hiramatsu Date: Thu, 30 Aug 2018 14:13:51 +0000 (+0900) Subject: selftests/ftrace: Add case number prefix to logfile X-Git-Tag: v4.20-rc1~84^2~37 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=7d0abba4293e555a5b1a6ea060cddd05f4ee357f;p=thirdparty%2Fkernel%2Flinux.git selftests/ftrace: Add case number prefix to logfile Add a case number prefix to each logfile. This makes it easier to find which logfile is corresponding to which failure. Signed-off-by: Masami Hiramatsu Acked-by: Steven Rostedt (VMware) Signed-off-by: Shuah Khan (Samsung OSG) --- diff --git a/tools/testing/selftests/ftrace/ftracetest b/tools/testing/selftests/ftrace/ftracetest index 8debd37038e44..3ca596255efff 100755 --- a/tools/testing/selftests/ftrace/ftracetest +++ b/tools/testing/selftests/ftrace/ftracetest @@ -284,13 +284,13 @@ __run_test() { # testfile # Run one test case run_test() { # testfile local testname=`basename $1` + testcase $1 if [ ! -z "$LOG_FILE" ] ; then - local testlog=`mktemp $LOG_DIR/${testname}-log.XXXXXX` + local testlog=`mktemp $LOG_DIR/${CASENO}-${testname}-log.XXXXXX` else local testlog=/proc/self/fd/1 fi export TMPDIR=`mktemp -d /tmp/ftracetest-dir.XXXXXX` - testcase $1 echo "execute$INSTANCE: "$1 > $testlog SIG_RESULT=0 if [ $VERBOSE -eq -1 ]; then