ktest: Fix check for new kernel success on rebooting to good kernel

The reboot function when rebooting back to a good kernel has a check
to make sure that a new kernel was indeed booted. But that check
uses a timeout value, which when calling the monitor will still
return success if the timeout is hit (no bug was found). It should
return an error to let the reboot code know that a new kernel was
not reached. Only the reboot code checks the return value of the
monitor.

Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
This commit is contained in:
Steven Rostedt (Red Hat) 2014-10-07 16:31:07 -04:00 коммит произвёл Steven Rostedt
Родитель fee9d3e61d
Коммит 995bc43140
1 изменённых файлов: 6 добавлений и 0 удалений

Просмотреть файл

@ -1450,6 +1450,12 @@ sub wait_for_monitor {
}
}
print "** Monitor flushed **\n";
# if stop is defined but wasn't hit, return error
# used by reboot (which wants to see a reboot)
if (defined($stop) && !$booted) {
$bug = 1;
}
return $bug;
}