linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] Input: sun4i-ts: add thermal driver dependency
@ 2015-01-28 15:17 Arnd Bergmann
  2015-01-29  7:50 ` Hans de Goede
  0 siblings, 1 reply; 7+ messages in thread
From: Arnd Bergmann @ 2015-01-28 15:17 UTC (permalink / raw)
  To: Dmitry Torokhov
  Cc: Hans de Goede, linux-input, linux-kernel, linux-arm-kernel, Chen-Yu Tsai

The sun4i-ts driver has had a dependency on the thermal code
since it was first merged, but this is not currently enforced
in Kconfig, so in some randconfig builds we get

drivers/built-in.o: In function `sun4i_ts_remove':
:(.text+0x2376f4): undefined reference to `thermal_zone_of_sensor_unregister'
drivers/built-in.o: In function `sun4i_ts_probe':
:(.text+0x237a94): undefined reference to `thermal_zone_of_sensor_register'
:(.text+0x237c00): undefined reference to `thermal_zone_of_sensor_unregister'

We need the dependency on THERMAL in order to ensure that this
driver becomes a loadable module if the thermal support itself
is modular, while the dependency on THERMAL_OF is a runtime dependency
and the driver will still build but not work if it is missing.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Fixes: 6decea7c5438e2 ("Input: add driver for Allwinner sunxi SoC's rtp controller")

diff --git a/drivers/input/touchscreen/Kconfig b/drivers/input/touchscreen/Kconfig
index 58917525126e..e2447f0063b7 100644
--- a/drivers/input/touchscreen/Kconfig
+++ b/drivers/input/touchscreen/Kconfig
@@ -943,6 +943,8 @@ config TOUCHSCREEN_SUN4I
 	tristate "Allwinner sun4i resistive touchscreen controller support"
 	depends on ARCH_SUNXI || COMPILE_TEST
 	depends on HWMON
+	depends on THERMAL
+	depends on THERMAL_OF || COMPILE_TEST
 	help
 	  This selects support for the resistive touchscreen controller
 	  found on Allwinner sunxi SoCs.


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

* Re: [PATCH] Input: sun4i-ts: add thermal driver dependency
  2015-01-28 15:17 [PATCH] Input: sun4i-ts: add thermal driver dependency Arnd Bergmann
@ 2015-01-29  7:50 ` Hans de Goede
  2015-01-29 18:51   ` Dmitry Torokhov
  0 siblings, 1 reply; 7+ messages in thread
From: Hans de Goede @ 2015-01-29  7:50 UTC (permalink / raw)
  To: Arnd Bergmann, Dmitry Torokhov
  Cc: linux-input, linux-kernel, linux-arm-kernel, Chen-Yu Tsai

Hi,

On 28-01-15 16:17, Arnd Bergmann wrote:
> The sun4i-ts driver has had a dependency on the thermal code
> since it was first merged,

The "since it was first merged bit" is not true, this is caused
by recent changes by ChenYu.

Other then that no objections from me against the proposed fix.

Regards,

Hans


  but this is not currently enforced
> in Kconfig, so in some randconfig builds we get
>
> drivers/built-in.o: In function `sun4i_ts_remove':
> :(.text+0x2376f4): undefined reference to `thermal_zone_of_sensor_unregister'
> drivers/built-in.o: In function `sun4i_ts_probe':
> :(.text+0x237a94): undefined reference to `thermal_zone_of_sensor_register'
> :(.text+0x237c00): undefined reference to `thermal_zone_of_sensor_unregister'
>
> We need the dependency on THERMAL in order to ensure that this
> driver becomes a loadable module if the thermal support itself
> is modular, while the dependency on THERMAL_OF is a runtime dependency
> and the driver will still build but not work if it is missing.
>
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> Fixes: 6decea7c5438e2 ("Input: add driver for Allwinner sunxi SoC's rtp controller")
>
> diff --git a/drivers/input/touchscreen/Kconfig b/drivers/input/touchscreen/Kconfig
> index 58917525126e..e2447f0063b7 100644
> --- a/drivers/input/touchscreen/Kconfig
> +++ b/drivers/input/touchscreen/Kconfig
> @@ -943,6 +943,8 @@ config TOUCHSCREEN_SUN4I
>   	tristate "Allwinner sun4i resistive touchscreen controller support"
>   	depends on ARCH_SUNXI || COMPILE_TEST
>   	depends on HWMON
> +	depends on THERMAL
> +	depends on THERMAL_OF || COMPILE_TEST
>   	help
>   	  This selects support for the resistive touchscreen controller
>   	  found on Allwinner sunxi SoCs.
>

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

* Re: [PATCH] Input: sun4i-ts: add thermal driver dependency
  2015-01-29  7:50 ` Hans de Goede
@ 2015-01-29 18:51   ` Dmitry Torokhov
  2015-02-11 18:24     ` Dmitry Torokhov
  2015-02-12  7:42     ` Chen-Yu Tsai
  0 siblings, 2 replies; 7+ messages in thread
From: Dmitry Torokhov @ 2015-01-29 18:51 UTC (permalink / raw)
  To: Hans de Goede
  Cc: Arnd Bergmann, linux-input, linux-kernel, linux-arm-kernel, Chen-Yu Tsai

On Thu, Jan 29, 2015 at 08:50:18AM +0100, Hans de Goede wrote:
> Hi,
> 
> On 28-01-15 16:17, Arnd Bergmann wrote:
> >The sun4i-ts driver has had a dependency on the thermal code
> >since it was first merged,
> 
> The "since it was first merged bit" is not true, this is caused
> by recent changes by ChenYu.
> 
> Other then that no objections from me against the proposed fix.
> 
> Regards,
> 
> Hans
> 
> 
>  but this is not currently enforced
> >in Kconfig, so in some randconfig builds we get
> >
> >drivers/built-in.o: In function `sun4i_ts_remove':
> >:(.text+0x2376f4): undefined reference to `thermal_zone_of_sensor_unregister'
> >drivers/built-in.o: In function `sun4i_ts_probe':
> >:(.text+0x237a94): undefined reference to `thermal_zone_of_sensor_register'
> >:(.text+0x237c00): undefined reference to `thermal_zone_of_sensor_unregister'
> >
> >We need the dependency on THERMAL in order to ensure that this
> >driver becomes a loadable module if the thermal support itself
> >is modular, while the dependency on THERMAL_OF is a runtime dependency
> >and the driver will still build but not work if it is missing.
> >
> >Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> >Fixes: 6decea7c5438e2 ("Input: add driver for Allwinner sunxi SoC's rtp controller")
> >
> >diff --git a/drivers/input/touchscreen/Kconfig b/drivers/input/touchscreen/Kconfig
> >index 58917525126e..e2447f0063b7 100644
> >--- a/drivers/input/touchscreen/Kconfig
> >+++ b/drivers/input/touchscreen/Kconfig
> >@@ -943,6 +943,8 @@ config TOUCHSCREEN_SUN4I
> >  	tristate "Allwinner sun4i resistive touchscreen controller support"
> >  	depends on ARCH_SUNXI || COMPILE_TEST
> >  	depends on HWMON
> >+	depends on THERMAL
> >+	depends on THERMAL_OF || COMPILE_TEST

THERMAL_OF does have proper stubs and I do not see why we need to force
having TERMAL even if we don't do compile test. Should the dependency be:

	depends on !THERMAL_OF || TERMAL

Thanks.

-- 
Dmitry

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

* Re: [PATCH] Input: sun4i-ts: add thermal driver dependency
  2015-01-29 18:51   ` Dmitry Torokhov
@ 2015-02-11 18:24     ` Dmitry Torokhov
  2015-02-12  7:01       ` Hans de Goede
  2015-02-12  7:42     ` Chen-Yu Tsai
  1 sibling, 1 reply; 7+ messages in thread
From: Dmitry Torokhov @ 2015-02-11 18:24 UTC (permalink / raw)
  To: Hans de Goede
  Cc: Arnd Bergmann, linux-input, linux-kernel, linux-arm-kernel, Chen-Yu Tsai

On Thu, Jan 29, 2015 at 10:51:51AM -0800, Dmitry Torokhov wrote:
> On Thu, Jan 29, 2015 at 08:50:18AM +0100, Hans de Goede wrote:
> > Hi,
> > 
> > On 28-01-15 16:17, Arnd Bergmann wrote:
> > >The sun4i-ts driver has had a dependency on the thermal code
> > >since it was first merged,
> > 
> > The "since it was first merged bit" is not true, this is caused
> > by recent changes by ChenYu.
> > 
> > Other then that no objections from me against the proposed fix.
> > 
> > Regards,
> > 
> > Hans
> > 
> > 
> >  but this is not currently enforced
> > >in Kconfig, so in some randconfig builds we get
> > >
> > >drivers/built-in.o: In function `sun4i_ts_remove':
> > >:(.text+0x2376f4): undefined reference to `thermal_zone_of_sensor_unregister'
> > >drivers/built-in.o: In function `sun4i_ts_probe':
> > >:(.text+0x237a94): undefined reference to `thermal_zone_of_sensor_register'
> > >:(.text+0x237c00): undefined reference to `thermal_zone_of_sensor_unregister'
> > >
> > >We need the dependency on THERMAL in order to ensure that this
> > >driver becomes a loadable module if the thermal support itself
> > >is modular, while the dependency on THERMAL_OF is a runtime dependency
> > >and the driver will still build but not work if it is missing.
> > >
> > >Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> > >Fixes: 6decea7c5438e2 ("Input: add driver for Allwinner sunxi SoC's rtp controller")
> > >
> > >diff --git a/drivers/input/touchscreen/Kconfig b/drivers/input/touchscreen/Kconfig
> > >index 58917525126e..e2447f0063b7 100644
> > >--- a/drivers/input/touchscreen/Kconfig
> > >+++ b/drivers/input/touchscreen/Kconfig
> > >@@ -943,6 +943,8 @@ config TOUCHSCREEN_SUN4I
> > >  	tristate "Allwinner sun4i resistive touchscreen controller support"
> > >  	depends on ARCH_SUNXI || COMPILE_TEST
> > >  	depends on HWMON
> > >+	depends on THERMAL
> > >+	depends on THERMAL_OF || COMPILE_TEST
> 
> THERMAL_OF does have proper stubs and I do not see why we need to force
> having TERMAL even if we don't do compile test. Should the dependency be:
> 
> 	depends on !THERMAL_OF || TERMAL

*ping*

Thanks.

-- 
Dmitry

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

* Re: [PATCH] Input: sun4i-ts: add thermal driver dependency
  2015-02-11 18:24     ` Dmitry Torokhov
@ 2015-02-12  7:01       ` Hans de Goede
  2015-02-12  7:38         ` Chen-Yu Tsai
  0 siblings, 1 reply; 7+ messages in thread
From: Hans de Goede @ 2015-02-12  7:01 UTC (permalink / raw)
  To: Dmitry Torokhov, Chen-Yu Tsai
  Cc: Arnd Bergmann, linux-input, linux-kernel, linux-arm-kernel

Hi,

On 11-02-15 19:24, Dmitry Torokhov wrote:
> On Thu, Jan 29, 2015 at 10:51:51AM -0800, Dmitry Torokhov wrote:
>> On Thu, Jan 29, 2015 at 08:50:18AM +0100, Hans de Goede wrote:
>>> Hi,
>>>
>>> On 28-01-15 16:17, Arnd Bergmann wrote:
>>>> The sun4i-ts driver has had a dependency on the thermal code
>>>> since it was first merged,
>>>
>>> The "since it was first merged bit" is not true, this is caused
>>> by recent changes by ChenYu.
>>>
>>> Other then that no objections from me against the proposed fix.
>>>
>>> Regards,
>>>
>>> Hans
>>>
>>>
>>>   but this is not currently enforced
>>>> in Kconfig, so in some randconfig builds we get
>>>>
>>>> drivers/built-in.o: In function `sun4i_ts_remove':
>>>> :(.text+0x2376f4): undefined reference to `thermal_zone_of_sensor_unregister'
>>>> drivers/built-in.o: In function `sun4i_ts_probe':
>>>> :(.text+0x237a94): undefined reference to `thermal_zone_of_sensor_register'
>>>> :(.text+0x237c00): undefined reference to `thermal_zone_of_sensor_unregister'
>>>>
>>>> We need the dependency on THERMAL in order to ensure that this
>>>> driver becomes a loadable module if the thermal support itself
>>>> is modular, while the dependency on THERMAL_OF is a runtime dependency
>>>> and the driver will still build but not work if it is missing.
>>>>
>>>> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
>>>> Fixes: 6decea7c5438e2 ("Input: add driver for Allwinner sunxi SoC's rtp controller")
>>>>
>>>> diff --git a/drivers/input/touchscreen/Kconfig b/drivers/input/touchscreen/Kconfig
>>>> index 58917525126e..e2447f0063b7 100644
>>>> --- a/drivers/input/touchscreen/Kconfig
>>>> +++ b/drivers/input/touchscreen/Kconfig
>>>> @@ -943,6 +943,8 @@ config TOUCHSCREEN_SUN4I
>>>>   	tristate "Allwinner sun4i resistive touchscreen controller support"
>>>>   	depends on ARCH_SUNXI || COMPILE_TEST
>>>>   	depends on HWMON
>>>> +	depends on THERMAL
>>>> +	depends on THERMAL_OF || COMPILE_TEST
>>
>> THERMAL_OF does have proper stubs and I do not see why we need to force
>> having TERMAL even if we don't do compile test. Should the dependency be:
>>
>> 	depends on !THERMAL_OF || TERMAL
>
> *ping*

ChenYu, since your patch causes this problem I'm assuming that you will come
up with a fix, is that correct ?

Regards,

Hans

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

* Re: [PATCH] Input: sun4i-ts: add thermal driver dependency
  2015-02-12  7:01       ` Hans de Goede
@ 2015-02-12  7:38         ` Chen-Yu Tsai
  0 siblings, 0 replies; 7+ messages in thread
From: Chen-Yu Tsai @ 2015-02-12  7:38 UTC (permalink / raw)
  To: Hans de Goede
  Cc: Dmitry Torokhov, Arnd Bergmann, linux-input, linux-kernel,
	linux-arm-kernel

Hi,

On Thu, Feb 12, 2015 at 3:01 PM, Hans de Goede <hdegoede@redhat.com> wrote:
> Hi,
>
>
> On 11-02-15 19:24, Dmitry Torokhov wrote:
>>
>> On Thu, Jan 29, 2015 at 10:51:51AM -0800, Dmitry Torokhov wrote:
>>>
>>> On Thu, Jan 29, 2015 at 08:50:18AM +0100, Hans de Goede wrote:
>>>>
>>>> Hi,
>>>>
>>>> On 28-01-15 16:17, Arnd Bergmann wrote:
>>>>>
>>>>> The sun4i-ts driver has had a dependency on the thermal code
>>>>> since it was first merged,
>>>>
>>>>
>>>> The "since it was first merged bit" is not true, this is caused
>>>> by recent changes by ChenYu.
>>>>
>>>> Other then that no objections from me against the proposed fix.
>>>>
>>>> Regards,
>>>>
>>>> Hans
>>>>
>>>>
>>>>   but this is not currently enforced
>>>>>
>>>>> in Kconfig, so in some randconfig builds we get
>>>>>
>>>>> drivers/built-in.o: In function `sun4i_ts_remove':
>>>>> :(.text+0x2376f4): undefined reference to
>>>>> `thermal_zone_of_sensor_unregister'
>>>>> drivers/built-in.o: In function `sun4i_ts_probe':
>>>>> :(.text+0x237a94): undefined reference to
>>>>> `thermal_zone_of_sensor_register'
>>>>> :(.text+0x237c00): undefined reference to
>>>>> `thermal_zone_of_sensor_unregister'
>>>>>
>>>>> We need the dependency on THERMAL in order to ensure that this
>>>>> driver becomes a loadable module if the thermal support itself
>>>>> is modular, while the dependency on THERMAL_OF is a runtime dependency
>>>>> and the driver will still build but not work if it is missing.
>>>>>
>>>>> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
>>>>> Fixes: 6decea7c5438e2 ("Input: add driver for Allwinner sunxi SoC's rtp
>>>>> controller")
>>>>>
>>>>> diff --git a/drivers/input/touchscreen/Kconfig
>>>>> b/drivers/input/touchscreen/Kconfig
>>>>> index 58917525126e..e2447f0063b7 100644
>>>>> --- a/drivers/input/touchscreen/Kconfig
>>>>> +++ b/drivers/input/touchscreen/Kconfig
>>>>> @@ -943,6 +943,8 @@ config TOUCHSCREEN_SUN4I
>>>>>         tristate "Allwinner sun4i resistive touchscreen controller
>>>>> support"
>>>>>         depends on ARCH_SUNXI || COMPILE_TEST
>>>>>         depends on HWMON
>>>>> +       depends on THERMAL
>>>>> +       depends on THERMAL_OF || COMPILE_TEST
>>>
>>>
>>> THERMAL_OF does have proper stubs and I do not see why we need to force
>>> having TERMAL even if we don't do compile test. Should the dependency be:
>>>
>>>         depends on !THERMAL_OF || TERMAL
>>
>>
>> *ping*
>
>
> ChenYu, since your patch causes this problem I'm assuming that you will come
> up with a fix, is that correct ?

Wasn't aware everyone was waiting on me. Patch coming right up.

ChenYu

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

* Re: [PATCH] Input: sun4i-ts: add thermal driver dependency
  2015-01-29 18:51   ` Dmitry Torokhov
  2015-02-11 18:24     ` Dmitry Torokhov
@ 2015-02-12  7:42     ` Chen-Yu Tsai
  1 sibling, 0 replies; 7+ messages in thread
From: Chen-Yu Tsai @ 2015-02-12  7:42 UTC (permalink / raw)
  To: Dmitry Torokhov
  Cc: Hans de Goede, Arnd Bergmann, linux-input, linux-kernel,
	linux-arm-kernel

On Fri, Jan 30, 2015 at 2:51 AM, Dmitry Torokhov
<dmitry.torokhov@gmail.com> wrote:
> On Thu, Jan 29, 2015 at 08:50:18AM +0100, Hans de Goede wrote:
>> Hi,
>>
>> On 28-01-15 16:17, Arnd Bergmann wrote:
>> >The sun4i-ts driver has had a dependency on the thermal code
>> >since it was first merged,
>>
>> The "since it was first merged bit" is not true, this is caused
>> by recent changes by ChenYu.
>>
>> Other then that no objections from me against the proposed fix.
>>
>> Regards,
>>
>> Hans
>>
>>
>>  but this is not currently enforced
>> >in Kconfig, so in some randconfig builds we get
>> >
>> >drivers/built-in.o: In function `sun4i_ts_remove':
>> >:(.text+0x2376f4): undefined reference to `thermal_zone_of_sensor_unregister'
>> >drivers/built-in.o: In function `sun4i_ts_probe':
>> >:(.text+0x237a94): undefined reference to `thermal_zone_of_sensor_register'
>> >:(.text+0x237c00): undefined reference to `thermal_zone_of_sensor_unregister'
>> >
>> >We need the dependency on THERMAL in order to ensure that this
>> >driver becomes a loadable module if the thermal support itself
>> >is modular, while the dependency on THERMAL_OF is a runtime dependency
>> >and the driver will still build but not work if it is missing.
>> >
>> >Signed-off-by: Arnd Bergmann <arnd@arndb.de>
>> >Fixes: 6decea7c5438e2 ("Input: add driver for Allwinner sunxi SoC's rtp controller")
>> >
>> >diff --git a/drivers/input/touchscreen/Kconfig b/drivers/input/touchscreen/Kconfig
>> >index 58917525126e..e2447f0063b7 100644
>> >--- a/drivers/input/touchscreen/Kconfig
>> >+++ b/drivers/input/touchscreen/Kconfig
>> >@@ -943,6 +943,8 @@ config TOUCHSCREEN_SUN4I
>> >     tristate "Allwinner sun4i resistive touchscreen controller support"
>> >     depends on ARCH_SUNXI || COMPILE_TEST
>> >     depends on HWMON
>> >+    depends on THERMAL
>> >+    depends on THERMAL_OF || COMPILE_TEST
>
> THERMAL_OF does have proper stubs and I do not see why we need to force
> having TERMAL even if we don't do compile test. Should the dependency be:
>
>         depends on !THERMAL_OF || TERMAL
                                    ^^^ typo

Yes this solves the problem.


ChenYu

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

end of thread, other threads:[~2015-02-12  7:42 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-01-28 15:17 [PATCH] Input: sun4i-ts: add thermal driver dependency Arnd Bergmann
2015-01-29  7:50 ` Hans de Goede
2015-01-29 18:51   ` Dmitry Torokhov
2015-02-11 18:24     ` Dmitry Torokhov
2015-02-12  7:01       ` Hans de Goede
2015-02-12  7:38         ` Chen-Yu Tsai
2015-02-12  7:42     ` Chen-Yu Tsai

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