summaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorSteven Rostedt <srostedt@redhat.com>2012-03-21 08:18:35 -0400
committerSteven Rostedt <rostedt@goodmis.org>2012-03-21 08:18:35 -0400
commit6ca996cc7cee88a6153158455a0ba8e1e79dcd2e (patch)
treea896e3d3a0f733f123a88a6f6594c14f4a69ed4e /tools
parent627977d83ad081c43c9bcd3ad1e89e816a752061 (diff)
downloadblackbird-op-linux-6ca996cc7cee88a6153158455a0ba8e1e79dcd2e.tar.gz
blackbird-op-linux-6ca996cc7cee88a6153158455a0ba8e1e79dcd2e.zip
ktest: Add warning when bugs are ignored
When IGNORE_ERRORS is set, ktest will not fail a test if a backtrace is detected. But this can be an issue if the user added it in the config but forgot to remove it. They may be left wondering why their test did not fail, or even worse, why their bisect gave the wrong commit. Add a warning in the output if IGNORE_WARNINGS is set, and ktest detects a kernel error. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
Diffstat (limited to 'tools')
-rwxr-xr-xtools/testing/ktest/ktest.pl15
1 files changed, 12 insertions, 3 deletions
diff --git a/tools/testing/ktest/ktest.pl b/tools/testing/ktest/ktest.pl
index 2b63190c9f64..0a5f6cb007af 100755
--- a/tools/testing/ktest/ktest.pl
+++ b/tools/testing/ktest/ktest.pl
@@ -1460,6 +1460,7 @@ sub get_sha1 {
sub monitor {
my $booted = 0;
my $bug = 0;
+ my $bug_ignored = 0;
my $skip_call_trace = 0;
my $loops;
@@ -1531,9 +1532,13 @@ sub monitor {
}
if ($full_line =~ /call trace:/i) {
- if (!$ignore_errors && !$bug && !$skip_call_trace) {
- $bug = 1;
- $failure_start = time;
+ if (!$bug && !$skip_call_trace) {
+ if ($ignore_errors) {
+ $bug_ignored = 1;
+ } else {
+ $bug = 1;
+ $failure_start = time;
+ }
}
}
@@ -1595,6 +1600,10 @@ sub monitor {
fail "failed - never got a boot prompt." and return 0;
}
+ if ($bug_ignored) {
+ doprint "WARNING: Call Trace detected but ignored due to IGNORE_ERRORS=1\n";
+ }
+
return 1;
}
OpenPOWER on IntegriCloud