[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CANDhNCoQU3x7tkXve0Tuwyo_WDTq8-pNbmsAHcABPJCy2txpog@mail.gmail.com>
Date: Fri, 13 Sep 2024 17:37:08 -0700
From: John Stultz <jstultz@...gle.com>
To: Christian Loehle <christian.loehle@....com>
Cc: LKML <linux-kernel@...r.kernel.org>, Joel Fernandes <joelaf@...gle.com>,
Qais Yousef <qyousef@...alina.io>, 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>,
Valentin Schneider <vschneid@...hat.com>, Steven Rostedt <rostedt@...dmis.org>,
Ben Segall <bsegall@...gle.com>, Zimuzo Ezeozue <zezeozue@...gle.com>, Mel Gorman <mgorman@...e.de>,
Will Deacon <will@...nel.org>, Waiman Long <longman@...hat.com>, Boqun Feng <boqun.feng@...il.com>,
"Paul E. McKenney" <paulmck@...nel.org>, Metin Kaya <Metin.Kaya@....com>,
Xuewen Yan <xuewen.yan94@...il.com>, K Prateek Nayak <kprateek.nayak@....com>,
Thomas Gleixner <tglx@...utronix.de>, Daniel Lezcano <daniel.lezcano@...aro.org>, kernel-team@...roid.com
Subject: Re: [RESEND x2][PATCH v12 5/7] sched: Consolidate pick_*_task to
task_is_pushable helper
On Thu, Sep 12, 2024 at 10:29 AM Christian Loehle
<christian.loehle@....com> wrote:
> On 9/10/24 23:12, John Stultz wrote:
> > +static inline
> > +bool task_is_pushable(struct rq *rq, struct task_struct *p, int cpu)
> > +{
> > + if (!task_on_cpu(rq, p) &&
> > + cpumask_test_cpu(cpu, &p->cpus_mask))
> > + return true;
> > +
> > + return false;
> > +}
>
> The slightly awkward
> if (condition)
> return true;
> return false;
>
> is more convenient for you for the tri-state later, I assume.
> Fine by me FWIW.
> Reviewed-by: Christian Loehle <christian.loehle@....com>
Thanks so much for the review! Very much appreciate it!
-john
Powered by blists - more mailing lists