Re: [PATCH v5] sched/rt: Use IPI to trigger RT task push migration instead of pulling
From: Peter Zijlstra <peterz@infradead.org>
Date: 2015-03-20 10:25:57
Also in:
lkml
From: Peter Zijlstra <peterz@infradead.org>
Date: 2015-03-20 10:25:57
Also in:
lkml
On Wed, Mar 18, 2015 at 02:49:46PM -0400, Steven Rostedt wrote:
+static int find_next_push_cpu(struct rq *rq)
+{
+ struct rq *next_rq;
+ int cpu;
+
+ while (1) {
We typically tend to write: for (;;), instead, however would a do { }
while () loop not make more sense here?
do {
cpu = rto_next_cpu(rq);
if (cpu >= nr_cpu_ids)
break;
next_rq = cpu_rq(cpu);
} while (next_rq->rt.highest_prio.next >= rq->rt.highest_prio.curr);
+ return cpu; +}