aboutsummaryrefslogtreecommitdiffstats
path: root/tools/testing/selftests/rcutorture/bin/parse-build.sh
diff options
context:
space:
mode:
authorPaul E. McKenney <paulmck@linux.vnet.ibm.com>2013-10-28 06:34:22 -0700
committerPaul E. McKenney <paulmck@linux.vnet.ibm.com>2013-12-03 10:11:18 -0800
commit6d40cc0cb4311d0c5aa4a106cc86a3d45a9ad86c (patch)
treedcbbd440ccea9f6b8272ada52bedcf0414fe4fa7 /tools/testing/selftests/rcutorture/bin/parse-build.sh
parentrcutorture: Record results from repeated runs of the same test scenario (diff)
downloadlinux-dev-6d40cc0cb4311d0c5aa4a106cc86a3d45a9ad86c.tar.xz
linux-dev-6d40cc0cb4311d0c5aa4a106cc86a3d45a9ad86c.zip
rcutorture: Flag errors and warnings with color coding
The output of the rcutorture scripts often requires interpretation, so this commit simplifies this interpretation by tagging messages as BUGs (colored red) or WARNINGs (colored yellow). Reported-by: Ingo Molnar <mingo@kernel.org> Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Greg KH <gregkh@linuxfoundation.org>
Diffstat (limited to '')
-rwxr-xr-xtools/testing/selftests/rcutorture/bin/parse-build.sh18
1 files changed, 14 insertions, 4 deletions
diff --git a/tools/testing/selftests/rcutorture/bin/parse-build.sh b/tools/testing/selftests/rcutorture/bin/parse-build.sh
index 2e0e9f7ebbb0..9da2c7ba3fce 100755
--- a/tools/testing/selftests/rcutorture/bin/parse-build.sh
+++ b/tools/testing/selftests/rcutorture/bin/parse-build.sh
@@ -30,18 +30,28 @@
T=$1
title=$2
+. functions.sh
+
if grep -q CC < $T
then
:
else
- echo $title no build
+ print_bug $title no build
exit 1
fi
-if egrep -q "error:|rcu[^/]*\.c.*warning:|rcu.*\.h.*warning:" < $T
+if grep -q "error:" < $T
+then
+ print_bug $title build errors:
+ grep "error:" < $T
+ exit 2
+fi
+exit 0
+
+if egrep -q "rcu[^/]*\.c.*warning:|rcu.*\.h.*warning:" < $T
then
- echo $title build errors:
- egrep "error:|rcu[^/]*\.c.*warning:|rcu.*\.h.*warning:" < $T
+ print_warning $title build errors:
+ egrep "rcu[^/]*\.c.*warning:|rcu.*\.h.*warning:" < $T
exit 2
fi
exit 0