Commit b60f796c authored by Andrew Morton's avatar Andrew Morton Committed by Linus Torvalds

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: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 4501980a
...@@ -349,6 +349,10 @@ static int watchdog(void *unused) ...@@ -349,6 +349,10 @@ static int watchdog(void *unused)
set_current_state(TASK_INTERRUPTIBLE); set_current_state(TASK_INTERRUPTIBLE);
} }
/*
* Drop the policy/priority elevation during thread exit to avoid a
* scheduling latency spike.
*/
__set_current_state(TASK_RUNNING); __set_current_state(TASK_RUNNING);
sched_setscheduler(current, SCHED_NORMAL, &param); sched_setscheduler(current, SCHED_NORMAL, &param);
return 0; return 0;
......
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