linux-next.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
To: Stephen Rothwell <sfr@canb.auug.org.au>
Cc: linux-next@vger.kernel.org, LKML <linux-kernel@vger.kernel.org>,
	Dave Jones <davej@redhat.com>
Subject: Re: linux-next: Tree for July 10 (cpufreq oops)
Date: Fri, 10 Jul 2009 20:54:37 +0200	[thread overview]
Message-ID: <200907102054.37956.bzolnier@gmail.com> (raw)
In-Reply-To: <20090710151846.c7ebec37.sfr@canb.auug.org.au>

On Friday 10 July 2009 07:18:46 Stephen Rothwell wrote:
> Hi all,
> 
> Changes since 20090709:
 
[ this particular problem goes back to next-20090709 ]

From: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Subject: [PATCH] cpufreq: fix OOPS in __cpufreq_governor()

commit 0d923c15b774bed3491400bae6db50481ac8b9e4 ("[CPUFREQ] Factor out
policy setting from cpufreq_add_dev") accidentally reordered new_policy
setup and policy->governor reset.

Fix it, also update comment to match the function name while at it.

Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
---
 drivers/cpufreq/cpufreq.c |    7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

Index: b/drivers/cpufreq/cpufreq.c
===================================================================
--- a/drivers/cpufreq/cpufreq.c
+++ b/drivers/cpufreq/cpufreq.c
@@ -896,10 +896,11 @@ int cpufreq_add_dev_interface(unsigned i
 	if (ret)
 		goto err_out_kobj_put;
 
-	policy->governor = NULL; /* to assure that the starting sequence is
-				  * run in cpufreq_set_policy */
+	memcpy(&new_policy, policy, sizeof(new_policy));
+
+	/* assure that the starting sequence is run in __cpufreq_set_policy */
+	policy->governor = NULL;
 
-	memcpy(&new_policy, policy, sizeof(struct cpufreq_policy));
 	/* set default policy */
 	ret = __cpufreq_set_policy(policy, &new_policy);
 	policy->user_policy.policy = policy->policy;

  reply	other threads:[~2009-07-10 18:48 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-07-10  5:18 linux-next: Tree for July 10 Stephen Rothwell
2009-07-10 18:54 ` Bartlomiej Zolnierkiewicz [this message]
2009-07-10 19:07   ` linux-next: Tree for July 10 (cpufreq oops) Dave Jones

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=200907102054.37956.bzolnier@gmail.com \
    --to=bzolnier@gmail.com \
    --cc=davej@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-next@vger.kernel.org \
    --cc=sfr@canb.auug.org.au \
    /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).