From: Qian Cai <cai@lca.pw>
To: "Rafael J. Wysocki" <rafael@kernel.org>
Cc: "Rafael J. Wysocki" <rjw@rjwysocki.net>,
elver@google.com, Linux PM <linux-pm@vger.kernel.org>,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH -next] power/qos: fix a data race in pm_qos_*_value
Date: Sun, 23 Feb 2020 20:01:33 -0500 [thread overview]
Message-ID: <62491094-D13B-4EED-8190-4AA4EB77036B@lca.pw> (raw)
In-Reply-To: <CAJZ5v0iSEV9S=zTa9++vUCO6GTfBE2sxNY+b4mMMt4Y6RCRvjA@mail.gmail.com>
> On Feb 23, 2020, at 7:12 PM, Rafael J. Wysocki <rafael@kernel.org> wrote:
>
> It may be a bug under certain conditions, but you don't mention what
> conditions they are. Reporting it as a general bug is not accurate at
> the very least.
Could we rule out load tearing, store tearing and reload of global_req in cpuidle_governor_latency() for all compilers and architectures which could introduce logic bugs?
int global_req = cpu_latency_qos_limit();
if (device_req > global_req)
device_req = global_req;
If under register pressure, the compiler might get ride of the tmp variable, i.e.,
If (device_req > cpu_latency_qos_limit())
—-> race with the writer.
device_req = cpu_latency_qos_limit();
next prev parent reply other threads:[~2020-02-24 1:01 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-02-21 21:09 Qian Cai
2020-02-24 0:12 ` Rafael J. Wysocki
2020-02-24 1:01 ` Qian Cai [this message]
2020-02-24 9:54 ` Rafael J. Wysocki
2020-02-24 19:02 ` Qian Cai
2020-02-26 0:10 ` Rafael J. Wysocki
2020-02-26 0:34 ` Qian Cai
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=62491094-D13B-4EED-8190-4AA4EB77036B@lca.pw \
--to=cai@lca.pw \
--cc=elver@google.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pm@vger.kernel.org \
--cc=rafael@kernel.org \
--cc=rjw@rjwysocki.net \
/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
all inboxes | Powered by JetHome®