linux-pm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Viresh Kumar <viresh.kumar@linaro.org>
To: Richard Cochran <rcochran@linutronix.de>
Cc: linux-kernel@vger.kernel.org, rt@linutronix.de,
	Dirk Brandewie <dirk.brandewie@gmail.com>,
	"Rafael J. Wysocki" <rafael.j.wysocki@intel.com>,
	linux-pm@vger.kernel.org
Subject: Re: [PATCH v2] cpufreq: Make cpufreq_quick_get() safe to call.
Date: Sat, 12 Mar 2016 06:52:37 +0700	[thread overview]
Message-ID: <20160311235237.GA27500@vireshk-mac-ubuntu> (raw)
In-Reply-To: <1457685787-6046-1-git-send-email-rcochran@linutronix.de>

On 11-03-16, 09:43, Richard Cochran wrote:
> The function, cpufreq_quick_get, accesses the global 'cpufreq_driver' and
> its fields without taking the associated lock, cpufreq_driver_lock.
> 
> Without the locking, nothing guarantees that 'cpufreq_driver' remains
> consistent during the call.  This patch fixes the issue by taking the lock
> before accessing the data structure.
> 
> Cc: Dirk Brandewie <dirk.brandewie@gmail.com>
> Cc: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
> Cc: Viresh Kumar <viresh.kumar@linaro.org>
> Cc: linux-pm@vger.kernel.org
> Signed-off-by: Richard Cochran <rcochran@linutronix.de>
> ---
>  drivers/cpufreq/cpufreq.c | 12 ++++++++++--
>  1 file changed, 10 insertions(+), 2 deletions(-)

Acked-by: Viresh Kumar <viresh.kumar@linaro.org>

-- 
viresh

  reply	other threads:[~2016-03-11 23:52 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1457622636-10028-1-git-send-email-rcochran@linutronix.de>
2016-03-10 22:20 ` [PATCH] cpufreq: Make cpufreq_quick_get() safe to call Rafael J. Wysocki
2016-03-11  2:23   ` Rafael J. Wysocki
2016-03-11  8:43     ` [PATCH v2] " Richard Cochran
2016-03-11 23:52       ` Viresh Kumar [this message]
2016-03-18 23:34         ` Rafael J. Wysocki

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=20160311235237.GA27500@vireshk-mac-ubuntu \
    --to=viresh.kumar@linaro.org \
    --cc=dirk.brandewie@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=rafael.j.wysocki@intel.com \
    --cc=rcochran@linutronix.de \
    --cc=rt@linutronix.de \
    /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;
as well as URLs for NNTP newsgroup(s).