From: Peter Zijlstra <peterz@infradead.org>
To: Patrick Bellasi <patrick.bellasi@matbug.net>
Cc: Qais Yousef <qais.yousef@arm.com>, Ingo Molnar <mingo@redhat.com>,
Juri Lelli <juri.lelli@redhat.com>,
Vincent Guittot <vincent.guittot@linaro.org>,
Dietmar Eggemann <dietmar.eggemann@arm.com>,
Steven Rostedt <rostedt@goodmis.org>,
Ben Segall <bsegall@google.com>, Mel Gorman <mgorman@suse.de>,
Chris Redpath <chris.redpath@arm.com>,
Lukasz Luba <lukasz.luba@arm.com>,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2 2/2] sched/uclamp: Protect uclamp fast path code with static key
Date: Wed, 24 Jun 2020 14:28:19 +0200 [thread overview]
Message-ID: <20200624122819.GG4781@hirez.programming.kicks-ass.net> (raw)
In-Reply-To: <87pn9oor2t.derkling@matbug.net>
On Wed, Jun 24, 2020 at 09:34:02AM +0200, Patrick Bellasi wrote:
> > +static DEFINE_STATIC_KEY_TRUE(sched_uclamp_unused);
>
> I would personally prefer a non negated semantic.
That's what I said earlier as well.
> > + */
> > + if (static_branch_likely(&sched_uclamp_unused))
> > + return;
>
> Moreover, something like:
>
> if (static_key_false(&sched_uclamp_enabled))
> return;
>
> is not just good enough?
static_key_true/false() are the deprecated API.
next prev parent reply other threads:[~2020-06-24 12:28 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-06-19 17:20 [PATCH v2 0/2] sched: Optionally skip uclamp logic in fast path Qais Yousef
2020-06-19 17:20 ` [PATCH v2 1/2] sched/uclamp: Fix initialization of strut uclamp_rq Qais Yousef
2020-06-24 7:26 ` Patrick Bellasi
2020-06-24 10:36 ` Qais Yousef
2020-06-19 17:20 ` [PATCH v2 2/2] sched/uclamp: Protect uclamp fast path code with static key Qais Yousef
2020-06-24 7:34 ` Patrick Bellasi
2020-06-24 11:07 ` Qais Yousef
2020-06-24 12:28 ` Peter Zijlstra [this message]
2020-06-23 17:39 ` [PATCH v2 0/2] sched: Optionally skip uclamp logic in fast path Dietmar Eggemann
2020-06-24 9:00 ` Vincent Guittot
2020-06-24 12:26 ` Qais Yousef
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200624122819.GG4781@hirez.programming.kicks-ass.net \
--to=peterz@infradead.org \
--cc=bsegall@google.com \
--cc=chris.redpath@arm.com \
--cc=dietmar.eggemann@arm.com \
--cc=juri.lelli@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=lukasz.luba@arm.com \
--cc=mgorman@suse.de \
--cc=mingo@redhat.com \
--cc=patrick.bellasi@matbug.net \
--cc=qais.yousef@arm.com \
--cc=rostedt@goodmis.org \
--cc=vincent.guittot@linaro.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox