linux-pm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] thermal: imx: correct thermal driver load sequence
@ 2014-09-11  7:50 Bai Ping
  0 siblings, 0 replies; 3+ messages in thread
From: Bai Ping @ 2014-09-11  7:50 UTC (permalink / raw)
  To: rui.zhang, eduardo.valentin; +Cc: linux-pm

Thermal driver should be registered after cpufreq driver have
been registered and probed. Doing so is to make sure that thermal
driver can get the max cpu cooling states correctly when calling
get_property.

Signed-off-by: Bai Ping <b51503@freescale.com>
---
 drivers/thermal/imx_thermal.c | 11 +++++++++--
 1 file changed, 9 insertions(+), 2 deletions(-)

diff --git a/drivers/thermal/imx_thermal.c b/drivers/thermal/imx_thermal.c
index 45af765..d00aaaf 100644
--- a/drivers/thermal/imx_thermal.c
+++ b/drivers/thermal/imx_thermal.c
@@ -1,5 +1,5 @@
 /*
- * Copyright 2013 Freescale Semiconductor, Inc.
+ * Copyright 2013-2014 Freescale Semiconductor, Inc.
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License version 2 as
@@ -557,7 +557,14 @@ static struct platform_driver imx_thermal = {
 	.probe		= imx_thermal_probe,
 	.remove		= imx_thermal_remove,
 };
-module_platform_driver(imx_thermal);
+
+static int __init imx_thermal_init(void)
+{
+	return platform_driver_register(&imx_thermal);
+}
+
+late_initcall(imx_thermal_init);
+
 MODULE_AUTHOR("Freescale Semiconductor, Inc.");
 MODULE_DESCRIPTION("Thermal driver for Freescale i.MX SoCs");
-- 
1.9.1



^ permalink raw reply related	[flat|nested] 3+ messages in thread
* [PATCH] thermal: imx: correct thermal driver load sequence
@ 2014-09-11  8:04 Bai Ping
  2014-09-11 12:16 ` Eduardo Valentin
  0 siblings, 1 reply; 3+ messages in thread
From: Bai Ping @ 2014-09-11  8:04 UTC (permalink / raw)
  To: rui.zhang; +Cc: linux-pm

Thermal driver should be registered after cpufreq driver have
been registered and probed. Doing so is to make sure that thermal
driver can get the max cpu cooling states correctly when calling
get_property.

Signed-off-by: Bai Ping <b51503@freescale.com>
---
 drivers/thermal/imx_thermal.c | 11 +++++++++--
 1 file changed, 9 insertions(+), 2 deletions(-)

diff --git a/drivers/thermal/imx_thermal.c b/drivers/thermal/imx_thermal.c
index 45af765..d00aaaf 100644
--- a/drivers/thermal/imx_thermal.c
+++ b/drivers/thermal/imx_thermal.c
@@ -1,5 +1,5 @@
 /*
- * Copyright 2013 Freescale Semiconductor, Inc.
+ * Copyright 2013-2014 Freescale Semiconductor, Inc.
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License version 2 as
@@ -557,7 +557,14 @@ static struct platform_driver imx_thermal = {
 	.probe		= imx_thermal_probe,
 	.remove		= imx_thermal_remove,
 };
-module_platform_driver(imx_thermal);
+
+static int __init imx_thermal_init(void)
+{
+	return platform_driver_register(&imx_thermal);
+}
+
+late_initcall(imx_thermal_init);
+
 MODULE_AUTHOR("Freescale Semiconductor, Inc.");
 MODULE_DESCRIPTION("Thermal driver for Freescale i.MX SoCs");
-- 
1.9.1



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

end of thread, other threads:[~2014-09-11 12:16 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-09-11  7:50 [PATCH] thermal: imx: correct thermal driver load sequence Bai Ping
  -- strict thread matches above, loose matches on Subject: below --
2014-09-11  8:04 Bai Ping
2014-09-11 12:16 ` Eduardo Valentin

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