Re: [PATCH 4/6 v8] sched/fair: Add push task mechanism for fair
From: Vincent Guittot
Date: Thu Dec 04 2025 - 09:32:54 EST
On Thu, 4 Dec 2025 at 11:46, Peter Zijlstra <peterz@xxxxxxxxxxxxx> wrote:
>
> On Tue, Dec 02, 2025 at 07:12:40PM +0100, Vincent Guittot wrote:
>
>
> > +static void fair_add_pushable_task(struct rq *rq, struct task_struct *p)
> > +{
> > + if (sched_push_task_enabled() && fair_push_task(rq, p)) {
> > + plist_del(&p->pushable_tasks, &rq->cfs.pushable_tasks);
> > + plist_node_init(&p->pushable_tasks, p->prio);
> > + plist_add(&p->pushable_tasks, &rq->cfs.pushable_tasks);
> > + }
> > +}
>
> I might have asked before, but if there was an answer, I have forgotten
> :/
>
> Why is this a prio-list? It seems to me that we don't particularly care
> about keeping this push sorted by nice value, right?
We re-use the same struct plist_node pushable_tasks field as rt in task_struct
and we might add some ordering later based on slice as an example
but other than that no other reason
>