Skip to content

Commit

Permalink
ktest: Ignore warnings during reboot
Browse files Browse the repository at this point in the history
The reboot just wants to get to the next kernel. But if a warning (Call
Trace) appears, the monitor will report an error, and the reboot will
think something went wrong and power cycle the box, even though we
successfully made it to the next kernel.

Ignore warnings during the reboot until we get to the next kernel. It
will still timeout if we never get to the next kernel and then a power
cycle will happen. That's what we want it to do.

Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
  • Loading branch information
Steven Rostedt (Red Hat) committed Feb 5, 2013
1 parent d684553 commit 4c0b67a
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions tools/testing/ktest/ktest.pl
Original file line number Diff line number Diff line change
Expand Up @@ -1212,13 +1212,21 @@ sub reboot {
}

if (defined($time)) {

# We only want to get to the new kernel, don't fail
# if we stumble over a call trace.
my $save_ignore_errors = $ignore_errors;
$ignore_errors = 1;

# Look for the good kernel to boot
if (wait_for_monitor($time, "Linux version")) {
# reboot got stuck?
doprint "Reboot did not finish. Forcing power cycle\n";
run_command "$power_cycle";
}

$ignore_errors = $save_ignore_errors;

# Still need to wait for the reboot to finish
wait_for_monitor($time, $reboot_success_line);

Expand Down

0 comments on commit 4c0b67a

Please sign in to comment.