From: Namhyung Kim Date: Sat, 7 Jul 2012 07:49:02 +0000 (+0900) Subject: sched: Use task_rq_unlock() in __sched_setscheduler() X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=45afb1734fa6323a8ba08bd6c392ee227df67dde;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git sched: Use task_rq_unlock() in __sched_setscheduler() It seems there's no specific reason to open-code it. I guess commit 0122ec5b02f76 ("sched: Add p->pi_lock to task_rq_lock()") simply missed it. Let's be consistent with others. Signed-off-by: Namhyung Kim Signed-off-by: Peter Zijlstra Link: http://lkml.kernel.org/r/1341647342-6742-1-git-send-email-namhyung@kernel.org Signed-off-by: Ingo Molnar --- diff --git a/kernel/sched/core.c b/kernel/sched/core.c index 5d011ef4c0df..2cb4e7777998 100644 --- a/kernel/sched/core.c +++ b/kernel/sched/core.c @@ -4340,9 +4340,7 @@ recheck: */ if (unlikely(policy == p->policy && (!rt_policy(policy) || param->sched_priority == p->rt_priority))) { - - __task_rq_unlock(rq); - raw_spin_unlock_irqrestore(&p->pi_lock, flags); + task_rq_unlock(rq, p, &flags); return 0; }