linux-pm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Viresh Kumar <viresh.kumar@linaro.org>
To: rjw@sisk.pl
Cc: linaro-kernel@lists.linaro.org, patches@linaro.org,
	cpufreq@vger.kernel.org, linux-pm@vger.kernel.org,
	linux-kernel@vger.kernel.org, arnd.bergmann@linaro.org,
	Viresh Kumar <viresh.kumar@linaro.org>
Subject: [PATCH 07/15] cpufreq: integrator: initialize .owner field with THIS_MODULE
Date: Wed, 31 Jul 2013 19:49:16 +0530	[thread overview]
Message-ID: <8a9af45028b36379c29e10da6f7ea4be503df129.1375279948.git.viresh.kumar@linaro.org> (raw)
In-Reply-To: <cover.1375279948.git.viresh.kumar@linaro.org>
In-Reply-To: <cover.1375279948.git.viresh.kumar@linaro.org>

CPUFreq core does following at multiple places:
module_{get|put}(cpufreq_driver->owner)).

This is done to make sure module doesn't get unloaded if it is currently in use.
This will work only if the .owner field of cpufreq driver is initialized with a
valid pointer.

This field wasn't initialized for this driver, lets initialize it with
THIS_MODULE.

Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
---
 drivers/cpufreq/integrator-cpufreq.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/cpufreq/integrator-cpufreq.c b/drivers/cpufreq/integrator-cpufreq.c
index f7c99df..7205ea3 100644
--- a/drivers/cpufreq/integrator-cpufreq.c
+++ b/drivers/cpufreq/integrator-cpufreq.c
@@ -199,6 +199,7 @@ static struct cpufreq_driver integrator_driver = {
 	.target		= integrator_set_target,
 	.get		= integrator_get,
 	.init		= integrator_cpufreq_init,
+	.owner		= THIS_MODULE,
 	.name		= "integrator",
 };
 
-- 
1.7.12.rc2.18.g61b472e


  parent reply	other threads:[~2013-07-31 14:20 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-07-31 14:19 [PATCH 00/15] cpufreq: initialize drivers .owner field with THIS_MODULE Viresh Kumar
2013-07-31 14:19 ` [PATCH 01/15] cpufreq: arm_big_little: initialize " Viresh Kumar
2013-07-31 14:19 ` [PATCH 02/15] cpufreq: cpufreq-cpu0: " Viresh Kumar
2013-08-04 11:38   ` Shawn Guo
2013-07-31 14:19 ` [PATCH 03/15] cpufreq: davinci: " Viresh Kumar
2013-07-31 14:19 ` [PATCH 04/15] cpufreq: dbx500: " Viresh Kumar
2013-08-14 16:43   ` Linus Walleij
2013-07-31 14:19 ` [PATCH 05/15] cpufreq: exynos: " Viresh Kumar
2013-07-31 14:19 ` [PATCH 06/15] cpufreq: imx6q: " Viresh Kumar
2013-07-31 14:19 ` Viresh Kumar [this message]
2013-07-31 14:19 ` [PATCH 08/15] cpufreq: omap: " Viresh Kumar
2013-07-31 14:22   ` Santosh Shilimkar
2013-07-31 14:19 ` [PATCH 09/15] cpufreq: pxa: " Viresh Kumar
2013-07-31 14:19 ` [PATCH 10/15] cpufreq: s3c24xx: " Viresh Kumar
2013-07-31 14:19 ` [PATCH 11/15] cpufreq: s5pv210: " Viresh Kumar
2013-07-31 14:19 ` [PATCH 12/15] cpufreq: sa11**: " Viresh Kumar
2013-07-31 14:19 ` [PATCH 13/15] cpufreq: SPEAr: " Viresh Kumar
2013-07-31 14:19 ` [PATCH 14/15] cpufreq: Tegra: " Viresh Kumar
2013-07-31 19:13   ` Stephen Warren
2013-07-31 21:10     ` Rafael J. Wysocki
2013-07-31 14:19 ` [PATCH 15/15] cpufreq: Unicore: " Viresh Kumar
2013-07-31 16:36 ` [PATCH 00/15] cpufreq: initialize drivers " Sachin Kamat
2013-07-31 16:39   ` Viresh Kumar
2013-08-02  9:42     ` Sachin Kamat
2013-08-03 11:50 ` Viresh Kumar

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=8a9af45028b36379c29e10da6f7ea4be503df129.1375279948.git.viresh.kumar@linaro.org \
    --to=viresh.kumar@linaro.org \
    --cc=arnd.bergmann@linaro.org \
    --cc=cpufreq@vger.kernel.org \
    --cc=linaro-kernel@lists.linaro.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=patches@linaro.org \
    --cc=rjw@sisk.pl \
    /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).