aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/sched.c
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/sched.c')
-rw-r--r--kernel/sched.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/kernel/sched.c b/kernel/sched.c
index 18d38e4ec7ba..66ca5d9ba83c 100644
--- a/kernel/sched.c
+++ b/kernel/sched.c
@@ -2224,7 +2224,10 @@ unsigned long wait_task_inactive(struct task_struct *p, long match_state)
2224 * yield - it could be a while. 2224 * yield - it could be a while.
2225 */ 2225 */
2226 if (unlikely(on_rq)) { 2226 if (unlikely(on_rq)) {
2227 schedule_timeout_uninterruptible(1); 2227 ktime_t to = ktime_set(0, NSEC_PER_SEC/HZ);
2228
2229 set_current_state(TASK_UNINTERRUPTIBLE);
2230 schedule_hrtimeout(&to, HRTIMER_MODE_REL);
2228 continue; 2231 continue;
2229 } 2232 }
2230 2233