[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <e7c4d27f-6b98-4cd6-85b8-9c4672acdef4@linux.ibm.com>
Date: Sat, 22 Feb 2025 23:18:30 +0530
From: Madadi Vineeth Reddy <vineethr@...ux.ibm.com>
To: Abel Wu <wuyun.abel@...edance.com>
Cc: "open list:SCHEDULER" <linux-kernel@...r.kernel.org>,
Ingo Molnar <mingo@...hat.com>, Peter Zijlstra <peterz@...radead.org>,
Juri Lelli <juri.lelli@...hat.com>,
Vincent Guittot <vincent.guittot@...aro.org>,
Dietmar Eggemann <dietmar.eggemann@....com>,
Steven Rostedt <rostedt@...dmis.org>, Ben Segall <bsegall@...gle.com>,
Mel Gorman <mgorman@...e.de>, Josh Don <joshdon@...gle.com>,
Valentin Schneider <vschneid@...hat.com>,
Tianchen Ding <dtcccc@...ux.alibaba.com>,
Madadi Vineeth Reddy <vineethr@...ux.ibm.com>
Subject: Re: [PATCH 1/2] sched/fair: Do not let idle entities preempt others
On 21/02/25 16:42, Abel Wu wrote:
> A task with SCHED_IDLE policy doesn't preempt others by definition, and
> the semantics are intended to be preserved when extending to cgroups
> introduced in commit 304000390f88 ("sched: Cgroup SCHED_IDLE support").
[snip]
> diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c
> index 1c0ef435a7aa..4340178f29b7 100644
> --- a/kernel/sched/fair.c
> +++ b/kernel/sched/fair.c
> @@ -8778,12 +8778,15 @@ static void check_preempt_wakeup_fair(struct rq *rq, struct task_struct *p, int
> pse_is_idle = se_is_idle(pse);
>
> /*
> - * Preempt an idle entity in favor of a non-idle entity (and don't preempt
> - * in the inverse case).
> + * Preempt an idle entity in favor of a non-idle entity.
> */
> if (cse_is_idle && !pse_is_idle)
> goto preempt;
This patch doesn't apply cleanly on top of tip/sched/core because of the
commit f553741ac8c0 ("sched: Cancel the slice protection of the idle entity").
Please rebase it.
Thanks,
Madadi Vineeth Reddy
> - if (cse_is_idle != pse_is_idle)
> +
> + /*
> + * IDLE entities do not preempt others.
> + */
> + if (unlikely(pse_is_idle))
> return;
>
> /*
Powered by blists - more mailing lists