Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge branch 'sched-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip

* 'sched-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
sched: Fix sched rt group scheduling when hierachy is enabled

+9 -5
+9 -5
kernel/sched_rt.c
··· 210 210 211 211 static void sched_rt_rq_enqueue(struct rt_rq *rt_rq) 212 212 { 213 - int this_cpu = smp_processor_id(); 214 213 struct task_struct *curr = rq_of_rt_rq(rt_rq)->curr; 215 214 struct sched_rt_entity *rt_se; 216 215 217 - rt_se = rt_rq->tg->rt_se[this_cpu]; 216 + int cpu = cpu_of(rq_of_rt_rq(rt_rq)); 217 + 218 + rt_se = rt_rq->tg->rt_se[cpu]; 218 219 219 220 if (rt_rq->rt_nr_running) { 220 221 if (rt_se && !on_rt_rq(rt_se)) ··· 227 226 228 227 static void sched_rt_rq_dequeue(struct rt_rq *rt_rq) 229 228 { 230 - int this_cpu = smp_processor_id(); 231 229 struct sched_rt_entity *rt_se; 230 + int cpu = cpu_of(rq_of_rt_rq(rt_rq)); 232 231 233 - rt_se = rt_rq->tg->rt_se[this_cpu]; 232 + rt_se = rt_rq->tg->rt_se[cpu]; 234 233 235 234 if (rt_se && on_rt_rq(rt_se)) 236 235 dequeue_rt_entity(rt_se); ··· 566 565 if (rt_rq->rt_time || rt_rq->rt_nr_running) 567 566 idle = 0; 568 567 raw_spin_unlock(&rt_rq->rt_runtime_lock); 569 - } else if (rt_rq->rt_nr_running) 568 + } else if (rt_rq->rt_nr_running) { 570 569 idle = 0; 570 + if (!rt_rq_throttled(rt_rq)) 571 + enqueue = 1; 572 + } 571 573 572 574 if (enqueue) 573 575 sched_rt_rq_enqueue(rt_rq);