highest_prio.curr is actually a more accurate way to keep track ofthe pull_rt_task() threshold since it is always up to date, evenif the "next" task migrates during double_lock. Therefore, stoplooking at the "next" task object and simply use the highest_prio.curr.

@@ -1259,12 +1249,9 @@ static int pull_rt_task(struct rq *this_rq) * This is just that p is wakeing up and hasn't * had a chance to schedule. We only pull * p if it is lower in priority than the- * current task on the run queue or- * this_rq next task is lower in prio than- * the current task on that rq.+ * current task on the run queue */- if (p->prio < src_rq->curr->prio ||- (next && next->prio < src_rq->curr->prio))+ if (p->prio < src_rq->curr->prio) goto skip;

ret = 1;@@ -1277,13 +1264,7 @@ static int pull_rt_task(struct rq *this_rq) * case there's an even higher prio task * in another runqueue. (low likelyhood * but possible)- *- * Update next so that we won't pick a task- * on another cpu with a priority lower (or equal)- * than the one we just picked. */- next = p;- } skip: double_unlock_balance(this_rq, src_rq);