Commit 436e61d9 authored by Ingo Molnar's avatar Ingo Molnar Committed by Greg Kroah-Hartman

fix the softlockup watchdog to actually work

patch a115d5ca in mainline.

this Xen related commit:

   commit 966812dc
   Author: Jeremy Fitzhardinge <jeremy@goop.org>
   Date:   Tue May 8 00:28:02 2007 -0700

       Ignore stolen time in the softlockup watchdog

broke the softlockup watchdog to never report any lockups. (!)

print_timestamp defaults to 0, this makes the following condition
always true:

	if (print_timestamp < (touch_timestamp + 1) ||

and we'll in essence never report soft lockups.

apparently the functionality of the soft lockup watchdog was never
actually tested with that patch applied ...
Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
Cc: Jeremy Fitzhardinge <jeremy@goop.org>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent 4d03fda8
...@@ -80,10 +80,11 @@ void softlockup_tick(void) ...@@ -80,10 +80,11 @@ void softlockup_tick(void)
print_timestamp = per_cpu(print_timestamp, this_cpu); print_timestamp = per_cpu(print_timestamp, this_cpu);
/* report at most once a second */ /* report at most once a second */
if (print_timestamp < (touch_timestamp + 1) || if ((print_timestamp >= touch_timestamp &&
did_panic || print_timestamp < (touch_timestamp + 1)) ||
!per_cpu(watchdog_task, this_cpu)) did_panic || !per_cpu(watchdog_task, this_cpu)) {
return; return;
}
/* do not print during early bootup: */ /* do not print during early bootup: */
if (unlikely(system_state != SYSTEM_RUNNING)) { if (unlikely(system_state != SYSTEM_RUNNING)) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment