sched: Fix buglet in return_cfs_rq_runtime()
authorPaul Turner <pjt@google.com>
Tue, 8 Nov 2011 04:26:34 +0000 (20:26 -0800)
committerIngo Molnar <mingo@elte.hu>
Wed, 16 Nov 2011 07:43:45 +0000 (08:43 +0100)
In return_cfs_rq_runtime() we want to return bandwidth when there are no
remaining tasks, not "return" when this is the case.

Signed-off-by: Paul Turner <pjt@google.com>
Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Link: http://lkml.kernel.org/r/20111108042736.623812423@google.com
Signed-off-by: Ingo Molnar <mingo@elte.hu>
kernel/sched_fair.c

index ba0e1f49a22f1ecc243d0a74e6ef09cc71e3ce49..a78ed2736ba79f02a201d8256bd9e0a56d57981e 100644 (file)
@@ -1756,7 +1756,7 @@ static void __return_cfs_rq_runtime(struct cfs_rq *cfs_rq)
 
 static __always_inline void return_cfs_rq_runtime(struct cfs_rq *cfs_rq)
 {
-       if (!cfs_rq->runtime_enabled || !cfs_rq->nr_running)
+       if (!cfs_rq->runtime_enabled || cfs_rq->nr_running)
                return;
 
        __return_cfs_rq_runtime(cfs_rq);