hc
2024-05-14 bedbef8ad3e75a304af6361af235302bcc61d06b
kernel/tools/testing/selftests/rcutorture/bin/kvm-find-errors.sh
....@@ -1,4 +1,5 @@
11 #!/bin/sh
2
+# SPDX-License-Identifier: GPL-2.0+
23 #
34 # Invoke a text editor on all console.log files for all runs with diagnostics,
45 # that is, on all such files having a console.log.diags counterpart.
....@@ -10,11 +11,18 @@
1011 #
1112 # The "directory" above should end with the date/time directory, for example,
1213 # "tools/testing/selftests/rcutorture/res/2018.02.25-14:27:27".
14
+# Returns error status reflecting the success (or not) of the specified run.
15
+#
16
+# Copyright (C) IBM Corporation, 2018
17
+#
18
+# Author: Paul E. McKenney <paulmck@linux.ibm.com>
1319
1420 rundir="${1}"
1521 if test -z "$rundir" -o ! -d "$rundir"
1622 then
23
+ echo Directory "$rundir" not found.
1724 echo Usage: $0 directory
25
+ exit 1
1826 fi
1927 editor=${EDITOR-vi}
2028
....@@ -51,6 +59,8 @@
5159 if test -n "$files"
5260 then
5361 $editor $files
62
+ exit 1
5463 else
5564 echo No errors in console logs.
65
+ exit 0
5666 fi