summaryrefslogtreecommitdiffstats
path: root/kernel/watchdog.c
diff options
context:
space:
mode:
authorAndrew Morton <akpm@linux-foundation.org>2012-03-23 15:01:56 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2012-03-23 16:58:32 -0700
commitb60f796c4ca72545327a069f12938360d833cce7 (patch)
treedea778b974b2a1396cd85a582557e273cb151b2c /kernel/watchdog.c
parent4501980aae221ed8120dee3491f799ecd75187ad (diff)
downloadlinux-b60f796c4ca72545327a069f12938360d833cce7.tar.bz2
kernel/watchdog.c: add comment to watchdog() exit path
Revelation from Peter. Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Cc: Don Zickus <dzickus@redhat.com> Cc: Ingo Molnar <mingo@elte.hu> Cc: Thomas Gleixner <tglx@tglx.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'kernel/watchdog.c')
-rw-r--r--kernel/watchdog.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/kernel/watchdog.c b/kernel/watchdog.c
index a01cb03b045a..df30ee08bdd4 100644
--- a/kernel/watchdog.c
+++ b/kernel/watchdog.c
@@ -349,6 +349,10 @@ static int watchdog(void *unused)
set_current_state(TASK_INTERRUPTIBLE);
}
+ /*
+ * Drop the policy/priority elevation during thread exit to avoid a
+ * scheduling latency spike.
+ */
__set_current_state(TASK_RUNNING);
sched_setscheduler(current, SCHED_NORMAL, &param);
return 0;