Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1316985 > unrolled thread
| Started by | Arnd Bergmann <arnd@arndb.de> |
|---|---|
| First post | 2016-01-25 17:50 +0100 |
| Last post | 2016-01-27 08:40 +0100 |
| Articles | 2 — 2 participants |
Back to article view | Back to linux.kernel
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
[PATCH 3/3] thermal: allow u8500-thermal driver to be a module Arnd Bergmann <arnd@arndb.de> - 2016-01-25 17:50 +0100
Re: [PATCH 3/3] thermal: allow u8500-thermal driver to be a module Lee Jones <lee.jones@linaro.org> - 2016-01-27 08:40 +0100
| From | Arnd Bergmann <arnd@arndb.de> |
|---|---|
| Date | 2016-01-25 17:50 +0100 |
| Subject | [PATCH 3/3] thermal: allow u8500-thermal driver to be a module |
| Message-ID | <qUSuZ-6M7-1@gated-at.bofh.it> |
When the thermal subsystem is a loadable module, the u8500 driver
fails to build:
drivers/thermal/built-in.o: In function `db8500_thermal_probe':
db8500_thermal.c:(.text+0x96c): undefined reference to `thermal_zone_device_register'
drivers/thermal/built-in.o: In function `db8500_thermal_work':
db8500_thermal.c:(.text+0xab4): undefined reference to `thermal_zone_device_update'
This changes the symbol to a tristate, so Kconfig can track the
dependency correctly.
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
drivers/mfd/db8500-prcmu.c | 3 +++
drivers/thermal/Kconfig | 4 ++--
2 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/drivers/mfd/db8500-prcmu.c b/drivers/mfd/db8500-prcmu.c
index 2f4a1279b094..c0a86aeb1733 100644
--- a/drivers/mfd/db8500-prcmu.c
+++ b/drivers/mfd/db8500-prcmu.c
@@ -2045,6 +2045,7 @@ int db8500_prcmu_config_hotmon(u8 low, u8 high)
return 0;
}
+EXPORT_SYMBOL_GPL(db8500_prcmu_config_hotmon);
static int config_hot_period(u16 val)
{
@@ -2071,11 +2072,13 @@ int db8500_prcmu_start_temp_sense(u16 cycles32k)
return config_hot_period(cycles32k);
}
+EXPORT_SYMBOL_GPL(db8500_prcmu_start_temp_sense);
int db8500_prcmu_stop_temp_sense(void)
{
return config_hot_period(0xFFFF);
}
+EXPORT_SYMBOL_GPL(db8500_prcmu_stop_temp_sense);
static int prcmu_a9wdog(u8 cmd, u8 d0, u8 d1, u8 d2, u8 d3)
{
diff --git a/drivers/thermal/Kconfig b/drivers/thermal/Kconfig
index 0852fd028dc9..7c92c09be213 100644
--- a/drivers/thermal/Kconfig
+++ b/drivers/thermal/Kconfig
@@ -237,8 +237,8 @@ config DOVE_THERMAL
framework.
config DB8500_THERMAL
- bool "DB8500 thermal management"
- depends on ARCH_U8500
+ tristate "DB8500 thermal management"
+ depends on MFD_DB8500_PRCMU
default y
help
Adds DB8500 thermal management implementation according to the thermal
--
2.7.0
[toc] | [next] | [standalone]
| From | Lee Jones <lee.jones@linaro.org> |
|---|---|
| Date | 2016-01-27 08:40 +0100 |
| Message-ID | <qVsRQ-8v1-9@gated-at.bofh.it> |
| In reply to | #1316985 |
On Mon, 25 Jan 2016, Arnd Bergmann wrote:
> When the thermal subsystem is a loadable module, the u8500 driver
> fails to build:
>
> drivers/thermal/built-in.o: In function `db8500_thermal_probe':
> db8500_thermal.c:(.text+0x96c): undefined reference to `thermal_zone_device_register'
> drivers/thermal/built-in.o: In function `db8500_thermal_work':
> db8500_thermal.c:(.text+0xab4): undefined reference to `thermal_zone_device_update'
>
> This changes the symbol to a tristate, so Kconfig can track the
> dependency correctly.
>
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> ---
> drivers/mfd/db8500-prcmu.c | 3 +++
> drivers/thermal/Kconfig | 4 ++--
> 2 files changed, 5 insertions(+), 2 deletions(-)
As this touches a core Thermal file, I think it's better off going in
via that tree. If that's a problem, I can take it with the relevant
Acks.
Acked-by: Lee Jones <lee.jones@linaro.org>
> diff --git a/drivers/mfd/db8500-prcmu.c b/drivers/mfd/db8500-prcmu.c
> index 2f4a1279b094..c0a86aeb1733 100644
> --- a/drivers/mfd/db8500-prcmu.c
> +++ b/drivers/mfd/db8500-prcmu.c
> @@ -2045,6 +2045,7 @@ int db8500_prcmu_config_hotmon(u8 low, u8 high)
>
> return 0;
> }
> +EXPORT_SYMBOL_GPL(db8500_prcmu_config_hotmon);
>
> static int config_hot_period(u16 val)
> {
> @@ -2071,11 +2072,13 @@ int db8500_prcmu_start_temp_sense(u16 cycles32k)
>
> return config_hot_period(cycles32k);
> }
> +EXPORT_SYMBOL_GPL(db8500_prcmu_start_temp_sense);
>
> int db8500_prcmu_stop_temp_sense(void)
> {
> return config_hot_period(0xFFFF);
> }
> +EXPORT_SYMBOL_GPL(db8500_prcmu_stop_temp_sense);
>
> static int prcmu_a9wdog(u8 cmd, u8 d0, u8 d1, u8 d2, u8 d3)
> {
> diff --git a/drivers/thermal/Kconfig b/drivers/thermal/Kconfig
> index 0852fd028dc9..7c92c09be213 100644
> --- a/drivers/thermal/Kconfig
> +++ b/drivers/thermal/Kconfig
> @@ -237,8 +237,8 @@ config DOVE_THERMAL
> framework.
>
> config DB8500_THERMAL
> - bool "DB8500 thermal management"
> - depends on ARCH_U8500
> + tristate "DB8500 thermal management"
> + depends on MFD_DB8500_PRCMU
> default y
> help
> Adds DB8500 thermal management implementation according to the thermal
--
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web