linux-pm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 00/15] cpufreq: initialize drivers .owner field with THIS_MODULE
@ 2013-07-31 14:19 Viresh Kumar
  2013-07-31 14:19 ` [PATCH 01/15] cpufreq: arm_big_little: initialize " Viresh Kumar
                   ` (16 more replies)
  0 siblings, 17 replies; 25+ messages in thread
From: Viresh Kumar @ 2013-07-31 14:19 UTC (permalink / raw)
  To: rjw
  Cc: linaro-kernel, patches, cpufreq, linux-pm, linux-kernel,
	arnd.bergmann, Viresh Kumar

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 many cpufreq driver, lets initialize it with
THIS_MODULE.

Rebased over: v3.11-rc3 and pushed here:

https://git.linaro.org/gitweb?p=people/vireshk/linux.git;a=shortlog;h=refs/heads/cpufreq-fix-owner

Viresh Kumar (15):
  cpufreq: arm_big_little: initialize .owner field with THIS_MODULE
  cpufreq: cpufreq-cpu0: initialize .owner field with THIS_MODULE
  cpufreq: davinci: initialize .owner field with THIS_MODULE
  cpufreq: dbx500: initialize .owner field with THIS_MODULE
  cpufreq: exynos: initialize .owner field with THIS_MODULE
  cpufreq: imx6q: initialize .owner field with THIS_MODULE
  cpufreq: integrator: initialize .owner field with THIS_MODULE
  cpufreq: omap: initialize .owner field with THIS_MODULE
  cpufreq: pxa: initialize .owner field with THIS_MODULE
  cpufreq: s3c24xx: initialize .owner field with THIS_MODULE
  cpufreq: s5pv210: initialize .owner field with THIS_MODULE
  cpufreq: sa11**: initialize .owner field with THIS_MODULE
  cpufreq: SPEAr: initialize .owner field with THIS_MODULE
  cpufreq: Tegra: initialize .owner field with THIS_MODULE
  cpufreq: Unicore: initialize .owner field with THIS_MODULE

 drivers/cpufreq/arm_big_little.c     | 1 +
 drivers/cpufreq/cpufreq-cpu0.c       | 1 +
 drivers/cpufreq/davinci-cpufreq.c    | 1 +
 drivers/cpufreq/dbx500-cpufreq.c     | 1 +
 drivers/cpufreq/exynos-cpufreq.c     | 1 +
 drivers/cpufreq/exynos5440-cpufreq.c | 1 +
 drivers/cpufreq/imx6q-cpufreq.c      | 1 +
 drivers/cpufreq/integrator-cpufreq.c | 1 +
 drivers/cpufreq/omap-cpufreq.c       | 1 +
 drivers/cpufreq/pxa2xx-cpufreq.c     | 1 +
 drivers/cpufreq/pxa3xx-cpufreq.c     | 1 +
 drivers/cpufreq/s3c24xx-cpufreq.c    | 1 +
 drivers/cpufreq/s5pv210-cpufreq.c    | 1 +
 drivers/cpufreq/sa1100-cpufreq.c     | 1 +
 drivers/cpufreq/sa1110-cpufreq.c     | 1 +
 drivers/cpufreq/spear-cpufreq.c      | 1 +
 drivers/cpufreq/tegra-cpufreq.c      | 1 +
 drivers/cpufreq/unicore2-cpufreq.c   | 1 +
 18 files changed, 18 insertions(+)

-- 
1.7.12.rc2.18.g61b472e


^ permalink raw reply	[flat|nested] 25+ messages in thread

* [PATCH 01/15] cpufreq: arm_big_little: initialize .owner field with THIS_MODULE
  2013-07-31 14:19 [PATCH 00/15] cpufreq: initialize drivers .owner field with THIS_MODULE Viresh Kumar
@ 2013-07-31 14:19 ` Viresh Kumar
  2013-07-31 14:19 ` [PATCH 02/15] cpufreq: cpufreq-cpu0: " Viresh Kumar
                   ` (15 subsequent siblings)
  16 siblings, 0 replies; 25+ messages in thread
From: Viresh Kumar @ 2013-07-31 14:19 UTC (permalink / raw)
  To: rjw
  Cc: linaro-kernel, patches, cpufreq, linux-pm, linux-kernel,
	arnd.bergmann, Viresh Kumar

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/arm_big_little.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/cpufreq/arm_big_little.c b/drivers/cpufreq/arm_big_little.c
index 3549f07..ba4d3b9 100644
--- a/drivers/cpufreq/arm_big_little.c
+++ b/drivers/cpufreq/arm_big_little.c
@@ -221,6 +221,7 @@ static struct cpufreq_driver bL_cpufreq_driver = {
 	.init			= bL_cpufreq_init,
 	.exit			= bL_cpufreq_exit,
 	.have_governor_per_policy = true,
+	.owner			= THIS_MODULE,
 	.attr			= bL_cpufreq_attr,
 };
 
-- 
1.7.12.rc2.18.g61b472e

^ permalink raw reply related	[flat|nested] 25+ messages in thread

* [PATCH 02/15] cpufreq: cpufreq-cpu0: initialize .owner field with THIS_MODULE
  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 ` Viresh Kumar
  2013-08-04 11:38   ` Shawn Guo
  2013-07-31 14:19 ` [PATCH 03/15] cpufreq: davinci: " Viresh Kumar
                   ` (14 subsequent siblings)
  16 siblings, 1 reply; 25+ messages in thread
From: Viresh Kumar @ 2013-07-31 14:19 UTC (permalink / raw)
  To: rjw
  Cc: linaro-kernel, patches, cpufreq, linux-pm, linux-kernel,
	arnd.bergmann, Viresh Kumar, Shawn Guo

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.

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

diff --git a/drivers/cpufreq/cpufreq-cpu0.c b/drivers/cpufreq/cpufreq-cpu0.c
index ad1fde2..a087bf1 100644
--- a/drivers/cpufreq/cpufreq-cpu0.c
+++ b/drivers/cpufreq/cpufreq-cpu0.c
@@ -169,6 +169,7 @@ static struct cpufreq_driver cpu0_cpufreq_driver = {
 	.init = cpu0_cpufreq_init,
 	.exit = cpu0_cpufreq_exit,
 	.name = "generic_cpu0",
+	.owner = THIS_MODULE,
 	.attr = cpu0_cpufreq_attr,
 };
 
-- 
1.7.12.rc2.18.g61b472e

^ permalink raw reply related	[flat|nested] 25+ messages in thread

* [PATCH 03/15] cpufreq: davinci: initialize .owner field with THIS_MODULE
  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-07-31 14:19 ` Viresh Kumar
  2013-07-31 14:19 ` [PATCH 04/15] cpufreq: dbx500: " Viresh Kumar
                   ` (13 subsequent siblings)
  16 siblings, 0 replies; 25+ messages in thread
From: Viresh Kumar @ 2013-07-31 14:19 UTC (permalink / raw)
  To: rjw
  Cc: linaro-kernel, patches, cpufreq, linux-pm, linux-kernel,
	arnd.bergmann, Viresh Kumar, Sekhar Nori

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.

Cc: Sekhar Nori <nsekhar@ti.com>
Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
---
 drivers/cpufreq/davinci-cpufreq.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/cpufreq/davinci-cpufreq.c b/drivers/cpufreq/davinci-cpufreq.c
index 551dd65..db30e54 100644
--- a/drivers/cpufreq/davinci-cpufreq.c
+++ b/drivers/cpufreq/davinci-cpufreq.c
@@ -178,6 +178,7 @@ static struct cpufreq_driver davinci_driver = {
 	.init		= davinci_cpu_init,
 	.exit		= davinci_cpu_exit,
 	.name		= "davinci",
+	.owner		= THIS_MODULE,
 	.attr		= davinci_cpufreq_attr,
 };
 
-- 
1.7.12.rc2.18.g61b472e

^ permalink raw reply related	[flat|nested] 25+ messages in thread

* [PATCH 04/15] cpufreq: dbx500: initialize .owner field with THIS_MODULE
  2013-07-31 14:19 [PATCH 00/15] cpufreq: initialize drivers .owner field with THIS_MODULE Viresh Kumar
                   ` (2 preceding siblings ...)
  2013-07-31 14:19 ` [PATCH 03/15] cpufreq: davinci: " Viresh Kumar
@ 2013-07-31 14:19 ` Viresh Kumar
  2013-08-14 16:43   ` Linus Walleij
  2013-07-31 14:19 ` [PATCH 05/15] cpufreq: exynos: " Viresh Kumar
                   ` (12 subsequent siblings)
  16 siblings, 1 reply; 25+ messages in thread
From: Viresh Kumar @ 2013-07-31 14:19 UTC (permalink / raw)
  To: rjw
  Cc: linaro-kernel, patches, cpufreq, linux-pm, linux-kernel,
	arnd.bergmann, Viresh Kumar, Linus Walleij

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.

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

diff --git a/drivers/cpufreq/dbx500-cpufreq.c b/drivers/cpufreq/dbx500-cpufreq.c
index 26321cd..2527f1d 100644
--- a/drivers/cpufreq/dbx500-cpufreq.c
+++ b/drivers/cpufreq/dbx500-cpufreq.c
@@ -120,6 +120,7 @@ static struct cpufreq_driver dbx500_cpufreq_driver = {
 	.get    = dbx500_cpufreq_getspeed,
 	.init   = dbx500_cpufreq_init,
 	.name   = "DBX500",
+	.owner  = THIS_MODULE,
 	.attr   = dbx500_cpufreq_attr,
 };
 
-- 
1.7.12.rc2.18.g61b472e

^ permalink raw reply related	[flat|nested] 25+ messages in thread

* [PATCH 05/15] cpufreq: exynos: initialize .owner field with THIS_MODULE
  2013-07-31 14:19 [PATCH 00/15] cpufreq: initialize drivers .owner field with THIS_MODULE Viresh Kumar
                   ` (3 preceding siblings ...)
  2013-07-31 14:19 ` [PATCH 04/15] cpufreq: dbx500: " Viresh Kumar
@ 2013-07-31 14:19 ` Viresh Kumar
  2013-07-31 14:19 ` [PATCH 06/15] cpufreq: imx6q: " Viresh Kumar
                   ` (11 subsequent siblings)
  16 siblings, 0 replies; 25+ messages in thread
From: Viresh Kumar @ 2013-07-31 14:19 UTC (permalink / raw)
  To: rjw
  Cc: linaro-kernel, patches, cpufreq, linux-pm, linux-kernel,
	arnd.bergmann, Viresh Kumar, Kukjin Kim

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.

Cc: Kukjin Kim <kgene.kim@samsung.com>
Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
---
 drivers/cpufreq/exynos-cpufreq.c     | 1 +
 drivers/cpufreq/exynos5440-cpufreq.c | 1 +
 2 files changed, 2 insertions(+)

diff --git a/drivers/cpufreq/exynos-cpufreq.c b/drivers/cpufreq/exynos-cpufreq.c
index 0d32f02..fe0bbce 100644
--- a/drivers/cpufreq/exynos-cpufreq.c
+++ b/drivers/cpufreq/exynos-cpufreq.c
@@ -278,6 +278,7 @@ static struct cpufreq_driver exynos_driver = {
 	.init		= exynos_cpufreq_cpu_init,
 	.exit		= exynos_cpufreq_cpu_exit,
 	.name		= "exynos_cpufreq",
+	.owner		= THIS_MODULE,
 	.attr		= exynos_cpufreq_attr,
 #ifdef CONFIG_PM
 	.suspend	= exynos_cpufreq_suspend,
diff --git a/drivers/cpufreq/exynos5440-cpufreq.c b/drivers/cpufreq/exynos5440-cpufreq.c
index 0c74018..d0d353c 100644
--- a/drivers/cpufreq/exynos5440-cpufreq.c
+++ b/drivers/cpufreq/exynos5440-cpufreq.c
@@ -344,6 +344,7 @@ static struct cpufreq_driver exynos_driver = {
 	.target		= exynos_target,
 	.get		= exynos_getspeed,
 	.init		= exynos_cpufreq_cpu_init,
+	.owner		= THIS_MODULE,
 	.name		= CPUFREQ_NAME,
 };
 
-- 
1.7.12.rc2.18.g61b472e

^ permalink raw reply related	[flat|nested] 25+ messages in thread

* [PATCH 06/15] cpufreq: imx6q: initialize .owner field with THIS_MODULE
  2013-07-31 14:19 [PATCH 00/15] cpufreq: initialize drivers .owner field with THIS_MODULE Viresh Kumar
                   ` (4 preceding siblings ...)
  2013-07-31 14:19 ` [PATCH 05/15] cpufreq: exynos: " Viresh Kumar
@ 2013-07-31 14:19 ` Viresh Kumar
  2013-07-31 14:19 ` [PATCH 07/15] cpufreq: integrator: " Viresh Kumar
                   ` (10 subsequent siblings)
  16 siblings, 0 replies; 25+ messages in thread
From: Viresh Kumar @ 2013-07-31 14:19 UTC (permalink / raw)
  To: rjw
  Cc: linaro-kernel, patches, cpufreq, linux-pm, linux-kernel,
	arnd.bergmann, Viresh Kumar, Shawn Guo

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.

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

diff --git a/drivers/cpufreq/imx6q-cpufreq.c b/drivers/cpufreq/imx6q-cpufreq.c
index e37cdae..adbda1a 100644
--- a/drivers/cpufreq/imx6q-cpufreq.c
+++ b/drivers/cpufreq/imx6q-cpufreq.c
@@ -209,6 +209,7 @@ static struct cpufreq_driver imx6q_cpufreq_driver = {
 	.init = imx6q_cpufreq_init,
 	.exit = imx6q_cpufreq_exit,
 	.name = "imx6q-cpufreq",
+	.owner = THIS_MODULE,
 	.attr = imx6q_cpufreq_attr,
 };
 
-- 
1.7.12.rc2.18.g61b472e

^ permalink raw reply related	[flat|nested] 25+ messages in thread

* [PATCH 07/15] cpufreq: integrator: initialize .owner field with THIS_MODULE
  2013-07-31 14:19 [PATCH 00/15] cpufreq: initialize drivers .owner field with THIS_MODULE Viresh Kumar
                   ` (5 preceding siblings ...)
  2013-07-31 14:19 ` [PATCH 06/15] cpufreq: imx6q: " Viresh Kumar
@ 2013-07-31 14:19 ` Viresh Kumar
  2013-07-31 14:19 ` [PATCH 08/15] cpufreq: omap: " Viresh Kumar
                   ` (9 subsequent siblings)
  16 siblings, 0 replies; 25+ messages in thread
From: Viresh Kumar @ 2013-07-31 14:19 UTC (permalink / raw)
  To: rjw
  Cc: linaro-kernel, patches, cpufreq, linux-pm, linux-kernel,
	arnd.bergmann, Viresh Kumar

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


^ permalink raw reply related	[flat|nested] 25+ messages in thread

* [PATCH 08/15] cpufreq: omap: initialize .owner field with THIS_MODULE
  2013-07-31 14:19 [PATCH 00/15] cpufreq: initialize drivers .owner field with THIS_MODULE Viresh Kumar
                   ` (6 preceding siblings ...)
  2013-07-31 14:19 ` [PATCH 07/15] cpufreq: integrator: " Viresh Kumar
@ 2013-07-31 14:19 ` Viresh Kumar
  2013-07-31 14:22   ` Santosh Shilimkar
  2013-07-31 14:19 ` [PATCH 09/15] cpufreq: pxa: " Viresh Kumar
                   ` (8 subsequent siblings)
  16 siblings, 1 reply; 25+ messages in thread
From: Viresh Kumar @ 2013-07-31 14:19 UTC (permalink / raw)
  To: rjw
  Cc: linaro-kernel, patches, cpufreq, linux-pm, linux-kernel,
	arnd.bergmann, Viresh Kumar, Santosh Shilimkar

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.

Cc: Santosh Shilimkar <santosh.shilimkar@ti.com>
Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
---
 drivers/cpufreq/omap-cpufreq.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/cpufreq/omap-cpufreq.c b/drivers/cpufreq/omap-cpufreq.c
index f31fcfc..5b18385 100644
--- a/drivers/cpufreq/omap-cpufreq.c
+++ b/drivers/cpufreq/omap-cpufreq.c
@@ -241,6 +241,7 @@ static struct cpufreq_driver omap_driver = {
 	.init		= omap_cpu_init,
 	.exit		= omap_cpu_exit,
 	.name		= "omap",
+	.owner		= THIS_MODULE,
 	.attr		= omap_cpufreq_attr,
 };
 
-- 
1.7.12.rc2.18.g61b472e

^ permalink raw reply related	[flat|nested] 25+ messages in thread

* [PATCH 09/15] cpufreq: pxa: initialize .owner field with THIS_MODULE
  2013-07-31 14:19 [PATCH 00/15] cpufreq: initialize drivers .owner field with THIS_MODULE Viresh Kumar
                   ` (7 preceding siblings ...)
  2013-07-31 14:19 ` [PATCH 08/15] cpufreq: omap: " Viresh Kumar
@ 2013-07-31 14:19 ` Viresh Kumar
  2013-07-31 14:19 ` [PATCH 10/15] cpufreq: s3c24xx: " Viresh Kumar
                   ` (7 subsequent siblings)
  16 siblings, 0 replies; 25+ messages in thread
From: Viresh Kumar @ 2013-07-31 14:19 UTC (permalink / raw)
  To: rjw
  Cc: linaro-kernel, patches, cpufreq, linux-pm, linux-kernel,
	arnd.bergmann, Viresh Kumar, Eric Miao

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.

Cc: Eric Miao <eric.y.miao@gmail.com>
Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
---
 drivers/cpufreq/pxa2xx-cpufreq.c | 1 +
 drivers/cpufreq/pxa3xx-cpufreq.c | 1 +
 2 files changed, 2 insertions(+)

diff --git a/drivers/cpufreq/pxa2xx-cpufreq.c b/drivers/cpufreq/pxa2xx-cpufreq.c
index fb3981a..d62781b 100644
--- a/drivers/cpufreq/pxa2xx-cpufreq.c
+++ b/drivers/cpufreq/pxa2xx-cpufreq.c
@@ -468,6 +468,7 @@ static struct cpufreq_driver pxa_cpufreq_driver = {
 	.target	= pxa_set_target,
 	.init	= pxa_cpufreq_init,
 	.get	= pxa_cpufreq_get,
+	.owner	= THIS_MODULE,
 	.name	= "PXA2xx",
 };
 
diff --git a/drivers/cpufreq/pxa3xx-cpufreq.c b/drivers/cpufreq/pxa3xx-cpufreq.c
index 9c92ef0..81727ec 100644
--- a/drivers/cpufreq/pxa3xx-cpufreq.c
+++ b/drivers/cpufreq/pxa3xx-cpufreq.c
@@ -232,6 +232,7 @@ static struct cpufreq_driver pxa3xx_cpufreq_driver = {
 	.target		= pxa3xx_cpufreq_set,
 	.init		= pxa3xx_cpufreq_init,
 	.get		= pxa3xx_cpufreq_get,
+	.owner		= THIS_MODULE,
 	.name		= "pxa3xx-cpufreq",
 };
 
-- 
1.7.12.rc2.18.g61b472e

^ permalink raw reply related	[flat|nested] 25+ messages in thread

* [PATCH 10/15] cpufreq: s3c24xx: initialize .owner field with THIS_MODULE
  2013-07-31 14:19 [PATCH 00/15] cpufreq: initialize drivers .owner field with THIS_MODULE Viresh Kumar
                   ` (8 preceding siblings ...)
  2013-07-31 14:19 ` [PATCH 09/15] cpufreq: pxa: " Viresh Kumar
@ 2013-07-31 14:19 ` Viresh Kumar
  2013-07-31 14:19 ` [PATCH 11/15] cpufreq: s5pv210: " Viresh Kumar
                   ` (6 subsequent siblings)
  16 siblings, 0 replies; 25+ messages in thread
From: Viresh Kumar @ 2013-07-31 14:19 UTC (permalink / raw)
  To: rjw
  Cc: linaro-kernel, patches, cpufreq, linux-pm, linux-kernel,
	arnd.bergmann, Viresh Kumar, Kukjin Kim

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.

Cc: Kukjin Kim <kgene.kim@samsung.com>
Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
---
 drivers/cpufreq/s3c24xx-cpufreq.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/cpufreq/s3c24xx-cpufreq.c b/drivers/cpufreq/s3c24xx-cpufreq.c
index 87781eb..c5a46cc 100644
--- a/drivers/cpufreq/s3c24xx-cpufreq.c
+++ b/drivers/cpufreq/s3c24xx-cpufreq.c
@@ -479,6 +479,7 @@ static struct cpufreq_driver s3c24xx_driver = {
 	.init		= s3c_cpufreq_init,
 	.suspend	= s3c_cpufreq_suspend,
 	.resume		= s3c_cpufreq_resume,
+	.owner		= THIS_MODULE,
 	.name		= "s3c24xx",
 };
 
-- 
1.7.12.rc2.18.g61b472e


^ permalink raw reply related	[flat|nested] 25+ messages in thread

* [PATCH 11/15] cpufreq: s5pv210: initialize .owner field with THIS_MODULE
  2013-07-31 14:19 [PATCH 00/15] cpufreq: initialize drivers .owner field with THIS_MODULE Viresh Kumar
                   ` (9 preceding siblings ...)
  2013-07-31 14:19 ` [PATCH 10/15] cpufreq: s3c24xx: " Viresh Kumar
@ 2013-07-31 14:19 ` Viresh Kumar
  2013-07-31 14:19 ` [PATCH 12/15] cpufreq: sa11**: " Viresh Kumar
                   ` (5 subsequent siblings)
  16 siblings, 0 replies; 25+ messages in thread
From: Viresh Kumar @ 2013-07-31 14:19 UTC (permalink / raw)
  To: rjw
  Cc: linaro-kernel, patches, cpufreq, linux-pm, linux-kernel,
	arnd.bergmann, Viresh Kumar, Kukjin Kim

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.

Cc: Kukjin Kim <kgene.kim@samsung.com>
Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
---
 drivers/cpufreq/s5pv210-cpufreq.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/cpufreq/s5pv210-cpufreq.c b/drivers/cpufreq/s5pv210-cpufreq.c
index 5c77570..9ebad24 100644
--- a/drivers/cpufreq/s5pv210-cpufreq.c
+++ b/drivers/cpufreq/s5pv210-cpufreq.c
@@ -609,6 +609,7 @@ static struct cpufreq_driver s5pv210_driver = {
 	.target		= s5pv210_target,
 	.get		= s5pv210_getspeed,
 	.init		= s5pv210_cpu_init,
+	.owner		= THIS_MODULE,
 	.name		= "s5pv210",
 #ifdef CONFIG_PM
 	.suspend	= s5pv210_cpufreq_suspend,
-- 
1.7.12.rc2.18.g61b472e

^ permalink raw reply related	[flat|nested] 25+ messages in thread

* [PATCH 12/15] cpufreq: sa11**: initialize .owner field with THIS_MODULE
  2013-07-31 14:19 [PATCH 00/15] cpufreq: initialize drivers .owner field with THIS_MODULE Viresh Kumar
                   ` (10 preceding siblings ...)
  2013-07-31 14:19 ` [PATCH 11/15] cpufreq: s5pv210: " Viresh Kumar
@ 2013-07-31 14:19 ` Viresh Kumar
  2013-07-31 14:19 ` [PATCH 13/15] cpufreq: SPEAr: " Viresh Kumar
                   ` (4 subsequent siblings)
  16 siblings, 0 replies; 25+ messages in thread
From: Viresh Kumar @ 2013-07-31 14:19 UTC (permalink / raw)
  To: rjw
  Cc: linaro-kernel, patches, cpufreq, linux-pm, linux-kernel,
	arnd.bergmann, Viresh Kumar

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/sa1100-cpufreq.c | 1 +
 drivers/cpufreq/sa1110-cpufreq.c | 1 +
 2 files changed, 2 insertions(+)

diff --git a/drivers/cpufreq/sa1100-cpufreq.c b/drivers/cpufreq/sa1100-cpufreq.c
index cff18e8..f41dbd7 100644
--- a/drivers/cpufreq/sa1100-cpufreq.c
+++ b/drivers/cpufreq/sa1100-cpufreq.c
@@ -233,6 +233,7 @@ static struct cpufreq_driver sa1100_driver __refdata = {
 	.target		= sa1100_target,
 	.get		= sa11x0_getspeed,
 	.init		= sa1100_cpu_init,
+	.owner		= THIS_MODULE,
 	.name		= "sa1100",
 };
 
diff --git a/drivers/cpufreq/sa1110-cpufreq.c b/drivers/cpufreq/sa1110-cpufreq.c
index 39c90b6..61627fb 100644
--- a/drivers/cpufreq/sa1110-cpufreq.c
+++ b/drivers/cpufreq/sa1110-cpufreq.c
@@ -349,6 +349,7 @@ static struct cpufreq_driver sa1110_driver __refdata = {
 	.target		= sa1110_target,
 	.get		= sa11x0_getspeed,
 	.init		= sa1110_cpu_init,
+	.owner		= THIS_MODULE,
 	.name		= "sa1110",
 };
 
-- 
1.7.12.rc2.18.g61b472e


^ permalink raw reply related	[flat|nested] 25+ messages in thread

* [PATCH 13/15] cpufreq: SPEAr: initialize .owner field with THIS_MODULE
  2013-07-31 14:19 [PATCH 00/15] cpufreq: initialize drivers .owner field with THIS_MODULE Viresh Kumar
                   ` (11 preceding siblings ...)
  2013-07-31 14:19 ` [PATCH 12/15] cpufreq: sa11**: " Viresh Kumar
@ 2013-07-31 14:19 ` Viresh Kumar
  2013-07-31 14:19 ` [PATCH 14/15] cpufreq: Tegra: " Viresh Kumar
                   ` (3 subsequent siblings)
  16 siblings, 0 replies; 25+ messages in thread
From: Viresh Kumar @ 2013-07-31 14:19 UTC (permalink / raw)
  To: rjw
  Cc: linaro-kernel, patches, cpufreq, linux-pm, linux-kernel,
	arnd.bergmann, Viresh Kumar

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/spear-cpufreq.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/cpufreq/spear-cpufreq.c b/drivers/cpufreq/spear-cpufreq.c
index c3efa7f..3c00dd5 100644
--- a/drivers/cpufreq/spear-cpufreq.c
+++ b/drivers/cpufreq/spear-cpufreq.c
@@ -212,6 +212,7 @@ static struct cpufreq_driver spear_cpufreq_driver = {
 	.get		= spear_cpufreq_get,
 	.init		= spear_cpufreq_init,
 	.exit		= spear_cpufreq_exit,
+	.owner		= THIS_MODULE,
 	.attr		= spear_cpufreq_attr,
 };
 
-- 
1.7.12.rc2.18.g61b472e

^ permalink raw reply related	[flat|nested] 25+ messages in thread

* [PATCH 14/15] cpufreq: Tegra: initialize .owner field with THIS_MODULE
  2013-07-31 14:19 [PATCH 00/15] cpufreq: initialize drivers .owner field with THIS_MODULE Viresh Kumar
                   ` (12 preceding siblings ...)
  2013-07-31 14:19 ` [PATCH 13/15] cpufreq: SPEAr: " Viresh Kumar
@ 2013-07-31 14:19 ` Viresh Kumar
  2013-07-31 19:13   ` Stephen Warren
  2013-07-31 14:19 ` [PATCH 15/15] cpufreq: Unicore: " Viresh Kumar
                   ` (2 subsequent siblings)
  16 siblings, 1 reply; 25+ messages in thread
From: Viresh Kumar @ 2013-07-31 14:19 UTC (permalink / raw)
  To: rjw
  Cc: linaro-kernel, patches, cpufreq, linux-pm, linux-kernel,
	arnd.bergmann, Viresh Kumar, Stephen Warren

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.

Cc: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
---
 drivers/cpufreq/tegra-cpufreq.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/cpufreq/tegra-cpufreq.c b/drivers/cpufreq/tegra-cpufreq.c
index cd66b85..fc0ea61 100644
--- a/drivers/cpufreq/tegra-cpufreq.c
+++ b/drivers/cpufreq/tegra-cpufreq.c
@@ -250,6 +250,7 @@ static struct cpufreq_driver tegra_cpufreq_driver = {
 	.init		= tegra_cpu_init,
 	.exit		= tegra_cpu_exit,
 	.name		= "tegra",
+	.owner		= THIS_MODULE,
 	.attr		= tegra_cpufreq_attr,
 };
 
-- 
1.7.12.rc2.18.g61b472e

^ permalink raw reply related	[flat|nested] 25+ messages in thread

* [PATCH 15/15] cpufreq: Unicore: initialize .owner field with THIS_MODULE
  2013-07-31 14:19 [PATCH 00/15] cpufreq: initialize drivers .owner field with THIS_MODULE Viresh Kumar
                   ` (13 preceding siblings ...)
  2013-07-31 14:19 ` [PATCH 14/15] cpufreq: Tegra: " Viresh Kumar
@ 2013-07-31 14:19 ` Viresh Kumar
  2013-07-31 16:36 ` [PATCH 00/15] cpufreq: initialize drivers " Sachin Kamat
  2013-08-03 11:50 ` Viresh Kumar
  16 siblings, 0 replies; 25+ messages in thread
From: Viresh Kumar @ 2013-07-31 14:19 UTC (permalink / raw)
  To: rjw
  Cc: linaro-kernel, patches, cpufreq, linux-pm, linux-kernel,
	arnd.bergmann, Viresh Kumar, Guan Xuetao

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.

Cc: Guan Xuetao <gxt@mprc.pku.edu.cn>
Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
---
 drivers/cpufreq/unicore2-cpufreq.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/cpufreq/unicore2-cpufreq.c b/drivers/cpufreq/unicore2-cpufreq.c
index 12fc904..93519f7 100644
--- a/drivers/cpufreq/unicore2-cpufreq.c
+++ b/drivers/cpufreq/unicore2-cpufreq.c
@@ -81,6 +81,7 @@ static struct cpufreq_driver ucv2_driver = {
 	.target		= ucv2_target,
 	.get		= ucv2_getspeed,
 	.init		= ucv2_cpu_init,
+	.owner		= THIS_MODULE,
 	.name		= "UniCore-II",
 };
 
-- 
1.7.12.rc2.18.g61b472e

^ permalink raw reply related	[flat|nested] 25+ messages in thread

* Re: [PATCH 08/15] cpufreq: omap: initialize .owner field with THIS_MODULE
  2013-07-31 14:19 ` [PATCH 08/15] cpufreq: omap: " Viresh Kumar
@ 2013-07-31 14:22   ` Santosh Shilimkar
  0 siblings, 0 replies; 25+ messages in thread
From: Santosh Shilimkar @ 2013-07-31 14:22 UTC (permalink / raw)
  To: Viresh Kumar
  Cc: rjw, linaro-kernel, patches, cpufreq, linux-pm, linux-kernel,
	arnd.bergmann

On Wednesday 31 July 2013 10:19 AM, Viresh Kumar wrote:
> 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.
> 
> Cc: Santosh Shilimkar <santosh.shilimkar@ti.com>
> Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
> ---
Looks fine.
Acked-by: Santosh Shilimkar <santosh.shilimkar@ti.com>

^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: [PATCH 00/15] cpufreq: initialize drivers .owner field with THIS_MODULE
  2013-07-31 14:19 [PATCH 00/15] cpufreq: initialize drivers .owner field with THIS_MODULE Viresh Kumar
                   ` (14 preceding siblings ...)
  2013-07-31 14:19 ` [PATCH 15/15] cpufreq: Unicore: " Viresh Kumar
@ 2013-07-31 16:36 ` Sachin Kamat
  2013-07-31 16:39   ` Viresh Kumar
  2013-08-03 11:50 ` Viresh Kumar
  16 siblings, 1 reply; 25+ messages in thread
From: Sachin Kamat @ 2013-07-31 16:36 UTC (permalink / raw)
  To: Viresh Kumar
  Cc: rjw, linaro-kernel, patches, cpufreq, linux-pm, linux-kernel,
	arnd.bergmann

Hi Viresh,

On 31 July 2013 19:49, Viresh Kumar <viresh.kumar@linaro.org> wrote:
> 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 many cpufreq driver, lets initialize it with
> THIS_MODULE.


Isn't it possible to do this inside cpufreq_register_driver function
in a similar way as done for platform_driver_register [1].

[1] https://lkml.org/lkml/2013/5/25/5

-- 
With warm regards,
Sachin

^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: [PATCH 00/15] cpufreq: initialize drivers .owner field with THIS_MODULE
  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
  0 siblings, 1 reply; 25+ messages in thread
From: Viresh Kumar @ 2013-07-31 16:39 UTC (permalink / raw)
  To: Sachin Kamat
  Cc: rjw, linaro-kernel, patches, cpufreq, linux-pm, linux-kernel,
	arnd.bergmann

On 31 July 2013 22:06, Sachin Kamat <sachin.kamat@linaro.org> wrote:
> Hi Viresh,
>
> On 31 July 2013 19:49, Viresh Kumar <viresh.kumar@linaro.org> wrote:
>> 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 many cpufreq driver, lets initialize it with
>> THIS_MODULE.
>
>
> Isn't it possible to do this inside cpufreq_register_driver function
> in a similar way as done for platform_driver_register [1].
>
> [1] https://lkml.org/lkml/2013/5/25/5

Don't know if its possible to set it to something other than THIS_MODULE.
In which case we want something else to be done.

^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: [PATCH 14/15] cpufreq: Tegra: initialize .owner field with THIS_MODULE
  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
  0 siblings, 1 reply; 25+ messages in thread
From: Stephen Warren @ 2013-07-31 19:13 UTC (permalink / raw)
  To: Viresh Kumar
  Cc: rjw, linaro-kernel, patches, cpufreq, linux-pm, linux-kernel,
	arnd.bergmann, Stephen Warren

On 07/31/2013 08:19 AM, Viresh Kumar wrote:
> 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.

Acked-by: Stephen Warren <swarren@nvidia.com>

I assume this is all part of a series you'll take through the cpufreq tree.

^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: [PATCH 14/15] cpufreq: Tegra: initialize .owner field with THIS_MODULE
  2013-07-31 19:13   ` Stephen Warren
@ 2013-07-31 21:10     ` Rafael J. Wysocki
  0 siblings, 0 replies; 25+ messages in thread
From: Rafael J. Wysocki @ 2013-07-31 21:10 UTC (permalink / raw)
  To: Stephen Warren
  Cc: Viresh Kumar, linaro-kernel, patches, cpufreq, linux-pm,
	linux-kernel, arnd.bergmann, Stephen Warren

On Wednesday, July 31, 2013 01:13:09 PM Stephen Warren wrote:
> On 07/31/2013 08:19 AM, Viresh Kumar wrote:
> > 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.
> 
> Acked-by: Stephen Warren <swarren@nvidia.com>
> 
> I assume this is all part of a series you'll take through the cpufreq tree.

I'm going to apply this series eventually, but I'd like some ACKs to accumulate
before doing that.

Thanks,
Rafael


-- 
I speak only for myself.
Rafael J. Wysocki, Intel Open Source Technology Center.

^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: [PATCH 00/15] cpufreq: initialize drivers .owner field with THIS_MODULE
  2013-07-31 16:39   ` Viresh Kumar
@ 2013-08-02  9:42     ` Sachin Kamat
  0 siblings, 0 replies; 25+ messages in thread
From: Sachin Kamat @ 2013-08-02  9:42 UTC (permalink / raw)
  To: Viresh Kumar
  Cc: rjw, linaro-kernel, patches, cpufreq, linux-pm, linux-kernel,
	arnd.bergmann

On 31 July 2013 22:09, Viresh Kumar <viresh.kumar@linaro.org> wrote:
> On 31 July 2013 22:06, Sachin Kamat <sachin.kamat@linaro.org> wrote:
>> Hi Viresh,
>>
>> On 31 July 2013 19:49, Viresh Kumar <viresh.kumar@linaro.org> wrote:
>>> 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 many cpufreq driver, lets initialize it with
>>> THIS_MODULE.
>>
>>
>> Isn't it possible to do this inside cpufreq_register_driver function
>> in a similar way as done for platform_driver_register [1].
>>
>> [1] https://lkml.org/lkml/2013/5/25/5
>
> Don't know if its possible to set it to something other than THIS_MODULE.
> In which case we want something else to be done.

Even I am curious to know if it is possible to set the owner to
something other than THIS_MODULE.

-- 
With warm regards,
Sachin

^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: [PATCH 00/15] cpufreq: initialize drivers .owner field with THIS_MODULE
  2013-07-31 14:19 [PATCH 00/15] cpufreq: initialize drivers .owner field with THIS_MODULE Viresh Kumar
                   ` (15 preceding siblings ...)
  2013-07-31 16:36 ` [PATCH 00/15] cpufreq: initialize drivers " Sachin Kamat
@ 2013-08-03 11:50 ` Viresh Kumar
  16 siblings, 0 replies; 25+ messages in thread
From: Viresh Kumar @ 2013-08-03 11:50 UTC (permalink / raw)
  To: rjw
  Cc: linaro-kernel, patches, cpufreq, linux-pm, linux-kernel,
	arnd.bergmann, Viresh Kumar

On 31 July 2013 19:49, Viresh Kumar <viresh.kumar@linaro.org> wrote:
> 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 many cpufreq driver, lets initialize it with
> THIS_MODULE.

You can drop this patchset now as .owner field is removed in the latest
patchset from me which is posted today:

"[PATCH 00/10] CPUFreq: Fixes & Cleanups for 3.12"

^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: [PATCH 02/15] cpufreq: cpufreq-cpu0: initialize .owner field with THIS_MODULE
  2013-07-31 14:19 ` [PATCH 02/15] cpufreq: cpufreq-cpu0: " Viresh Kumar
@ 2013-08-04 11:38   ` Shawn Guo
  0 siblings, 0 replies; 25+ messages in thread
From: Shawn Guo @ 2013-08-04 11:38 UTC (permalink / raw)
  To: Viresh Kumar
  Cc: rjw, linaro-kernel, patches, cpufreq, linux-pm, linux-kernel,
	arnd.bergmann

On Wed, Jul 31, 2013 at 07:49:11PM +0530, Viresh Kumar wrote:
> 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.
> 
> Cc: Shawn Guo <shawn.guo@linaro.org>
> Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>

For this and imx6q-cpufreq one,

Acked-by: Shawn Guo <shawn.guo@linaro.org>

> ---
>  drivers/cpufreq/cpufreq-cpu0.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/cpufreq/cpufreq-cpu0.c b/drivers/cpufreq/cpufreq-cpu0.c
> index ad1fde2..a087bf1 100644
> --- a/drivers/cpufreq/cpufreq-cpu0.c
> +++ b/drivers/cpufreq/cpufreq-cpu0.c
> @@ -169,6 +169,7 @@ static struct cpufreq_driver cpu0_cpufreq_driver = {
>  	.init = cpu0_cpufreq_init,
>  	.exit = cpu0_cpufreq_exit,
>  	.name = "generic_cpu0",
> +	.owner = THIS_MODULE,
>  	.attr = cpu0_cpufreq_attr,
>  };
>  
> -- 
> 1.7.12.rc2.18.g61b472e
> 


^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: [PATCH 04/15] cpufreq: dbx500: initialize .owner field with THIS_MODULE
  2013-07-31 14:19 ` [PATCH 04/15] cpufreq: dbx500: " Viresh Kumar
@ 2013-08-14 16:43   ` Linus Walleij
  0 siblings, 0 replies; 25+ messages in thread
From: Linus Walleij @ 2013-08-14 16:43 UTC (permalink / raw)
  To: Viresh Kumar
  Cc: Rafael J. Wysocki, linaro-kernel, Patch Tracking, cpufreq,
	linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org,
	Arnd Bergmann

On Wed, Jul 31, 2013 at 4:19 PM, Viresh Kumar <viresh.kumar@linaro.org> wrote:

> 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.
>
> Cc: Linus Walleij <linus.walleij@linaro.org>
> Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>

Acked-by: Linus Walleij <linus.walleij@linaro.org>

Yours,
Linus Walleij

^ permalink raw reply	[flat|nested] 25+ messages in thread

end of thread, other threads:[~2013-08-14 16:43 UTC | newest]

Thread overview: 25+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
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 ` [PATCH 07/15] cpufreq: integrator: " Viresh Kumar
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

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).