2014-01-25 22:29:25

by Richard Weinberger

[permalink] [raw]
Subject: [PATCH 2/2] thermal,rcar_thermal: Add dependency on HAS_IOMEM

Commit beeb5a1e (thermal: rcar-thermal: Enable driver compilation with COMPILE_TEST)
broke build on archs wihout io memory.

On archs like S390 or um this driver cannot build nor work.
Make it depend on HAS_IOMEM to bypass build failures.

drivers/thermal/rcar_thermal.c:404: undefined reference to `devm_ioremap_resource'
drivers/thermal/rcar_thermal.c:426: undefined reference to `devm_ioremap_resource'

Signed-off-by: Richard Weinberger <[email protected]>
---
drivers/thermal/Kconfig | 1 +
1 file changed, 1 insertion(+)

diff --git a/drivers/thermal/Kconfig b/drivers/thermal/Kconfig
index 35c0664..88efa8f 100644
--- a/drivers/thermal/Kconfig
+++ b/drivers/thermal/Kconfig
@@ -136,6 +136,7 @@ config SPEAR_THERMAL
config RCAR_THERMAL
tristate "Renesas R-Car thermal driver"
depends on ARCH_SHMOBILE || COMPILE_TEST
+ depends on HAS_IO_MEM
help
Enable this to plug the R-Car thermal sensor driver into the Linux
thermal framework.
--
1.8.1.4


2014-01-26 23:29:50

by Laurent Pinchart

[permalink] [raw]
Subject: Re: [PATCH 2/2] thermal,rcar_thermal: Add dependency on HAS_IOMEM

Hi Richard,

Thank you for the patch.

On Saturday 25 January 2014 23:29:14 Richard Weinberger wrote:
> Commit beeb5a1e (thermal: rcar-thermal: Enable driver compilation with
> COMPILE_TEST) broke build on archs wihout io memory.
>
> On archs like S390 or um this driver cannot build nor work.
> Make it depend on HAS_IOMEM to bypass build failures.
>
> drivers/thermal/rcar_thermal.c:404: undefined reference to
> `devm_ioremap_resource' drivers/thermal/rcar_thermal.c:426: undefined
> reference to `devm_ioremap_resource'
>
> Signed-off-by: Richard Weinberger <[email protected]>
> ---
> drivers/thermal/Kconfig | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/drivers/thermal/Kconfig b/drivers/thermal/Kconfig
> index 35c0664..88efa8f 100644
> --- a/drivers/thermal/Kconfig
> +++ b/drivers/thermal/Kconfig
> @@ -136,6 +136,7 @@ config SPEAR_THERMAL
> config RCAR_THERMAL
> tristate "Renesas R-Car thermal driver"
> depends on ARCH_SHMOBILE || COMPILE_TEST
> + depends on HAS_IO_MEM

Shouldn't that be HAS_IOMEM ?

> help
> Enable this to plug the R-Car thermal sensor driver into the Linux
> thermal framework.

--
Regards,

Laurent Pinchart

2014-01-26 23:34:19

by Richard Weinberger

[permalink] [raw]
Subject: Re: [PATCH 2/2] thermal,rcar_thermal: Add dependency on HAS_IOMEM

Am 27.01.2014 00:30, schrieb Laurent Pinchart:
> Hi Richard,
>
> Thank you for the patch.
>
> On Saturday 25 January 2014 23:29:14 Richard Weinberger wrote:
>> Commit beeb5a1e (thermal: rcar-thermal: Enable driver compilation with
>> COMPILE_TEST) broke build on archs wihout io memory.
>>
>> On archs like S390 or um this driver cannot build nor work.
>> Make it depend on HAS_IOMEM to bypass build failures.
>>
>> drivers/thermal/rcar_thermal.c:404: undefined reference to
>> `devm_ioremap_resource' drivers/thermal/rcar_thermal.c:426: undefined
>> reference to `devm_ioremap_resource'
>>
>> Signed-off-by: Richard Weinberger <[email protected]>
>> ---
>> drivers/thermal/Kconfig | 1 +
>> 1 file changed, 1 insertion(+)
>>
>> diff --git a/drivers/thermal/Kconfig b/drivers/thermal/Kconfig
>> index 35c0664..88efa8f 100644
>> --- a/drivers/thermal/Kconfig
>> +++ b/drivers/thermal/Kconfig
>> @@ -136,6 +136,7 @@ config SPEAR_THERMAL
>> config RCAR_THERMAL
>> tristate "Renesas R-Car thermal driver"
>> depends on ARCH_SHMOBILE || COMPILE_TEST
>> + depends on HAS_IO_MEM
>
> Shouldn't that be HAS_IOMEM ?

m(

Of course...will resend tomorrow.

>> help
>> Enable this to plug the R-Car thermal sensor driver into the Linux
>> thermal framework.
>

Thanks,
//richard

2014-02-27 06:58:25

by Zhang, Rui

[permalink] [raw]
Subject: Re: [PATCH 2/2] thermal,rcar_thermal: Add dependency on HAS_IOMEM

On Sat, 2014-01-25 at 23:29 +0100, Richard Weinberger wrote:
> Commit beeb5a1e (thermal: rcar-thermal: Enable driver compilation with COMPILE_TEST)
> broke build on archs wihout io memory.
>
> On archs like S390 or um this driver cannot build nor work.
> Make it depend on HAS_IOMEM to bypass build failures.
>
> drivers/thermal/rcar_thermal.c:404: undefined reference to `devm_ioremap_resource'
> drivers/thermal/rcar_thermal.c:426: undefined reference to `devm_ioremap_resource'
>
> Signed-off-by: Richard Weinberger <[email protected]>

Kuninori,

are you okay with this patch?

thanks,
rui

> ---
> drivers/thermal/Kconfig | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/drivers/thermal/Kconfig b/drivers/thermal/Kconfig
> index 35c0664..88efa8f 100644
> --- a/drivers/thermal/Kconfig
> +++ b/drivers/thermal/Kconfig
> @@ -136,6 +136,7 @@ config SPEAR_THERMAL
> config RCAR_THERMAL
> tristate "Renesas R-Car thermal driver"
> depends on ARCH_SHMOBILE || COMPILE_TEST
> + depends on HAS_IO_MEM
> help
> Enable this to plug the R-Car thermal sensor driver into the Linux
> thermal framework.

2014-02-28 00:44:13

by Kuninori Morimoto

[permalink] [raw]
Subject: Re: [PATCH 2/2] thermal,rcar_thermal: Add dependency on HAS_IOMEM


Hi Zhang

> On Sat, 2014-01-25 at 23:29 +0100, Richard Weinberger wrote:
> > Commit beeb5a1e (thermal: rcar-thermal: Enable driver compilation with COMPILE_TEST)
> > broke build on archs wihout io memory.
> >
> > On archs like S390 or um this driver cannot build nor work.
> > Make it depend on HAS_IOMEM to bypass build failures.
> >
> > drivers/thermal/rcar_thermal.c:404: undefined reference to `devm_ioremap_resource'
> > drivers/thermal/rcar_thermal.c:426: undefined reference to `devm_ioremap_resource'
> >
> > Signed-off-by: Richard Weinberger <[email protected]>
>
> Kuninori,
>
> are you okay with this patch?
(snip)
> > diff --git a/drivers/thermal/Kconfig b/drivers/thermal/Kconfig
> > index 35c0664..88efa8f 100644
> > --- a/drivers/thermal/Kconfig
> > +++ b/drivers/thermal/Kconfig
> > @@ -136,6 +136,7 @@ config SPEAR_THERMAL
> > config RCAR_THERMAL
> > tristate "Renesas R-Car thermal driver"
> > depends on ARCH_SHMOBILE || COMPILE_TEST
> > + depends on HAS_IO_MEM
> > help
> > Enable this to plug the R-Car thermal sensor driver into the Linux
> > thermal framework.

I guess

- HAS_IO_MEM
+ HAS_IOMEM


${LINUX}/lib/Makefile say

obj-$(CONFIG_HAS_IOMEM) += iomap_copy.o devres.o

2014-02-28 08:21:45

by Richard Weinberger

[permalink] [raw]
Subject: Re: [PATCH 2/2] thermal,rcar_thermal: Add dependency on HAS_IOMEM

Am 28.02.2014 01:44, schrieb Kuninori Morimoto:
>>> diff --git a/drivers/thermal/Kconfig b/drivers/thermal/Kconfig
>>> index 35c0664..88efa8f 100644
>>> --- a/drivers/thermal/Kconfig
>>> +++ b/drivers/thermal/Kconfig
>>> @@ -136,6 +136,7 @@ config SPEAR_THERMAL
>>> config RCAR_THERMAL
>>> tristate "Renesas R-Car thermal driver"
>>> depends on ARCH_SHMOBILE || COMPILE_TEST
>>> + depends on HAS_IO_MEM
>>> help
>>> Enable this to plug the R-Car thermal sensor driver into the Linux
>>> thermal framework.
>
> I guess
>
> - HAS_IO_MEM
> + HAS_IOMEM

Yeah, this has been resolved in v2:
https://lkml.org/lkml/2014/1/27/59

Thanks,
//richard

2014-02-28 09:30:58

by Kuninori Morimoto

[permalink] [raw]
Subject: Re: [PATCH 2/2] thermal,rcar_thermal: Add dependency on HAS_IOMEM


Hi Richard, Zhang

> >>> diff --git a/drivers/thermal/Kconfig b/drivers/thermal/Kconfig
> >>> index 35c0664..88efa8f 100644
> >>> --- a/drivers/thermal/Kconfig
> >>> +++ b/drivers/thermal/Kconfig
> >>> @@ -136,6 +136,7 @@ config SPEAR_THERMAL
> >>> config RCAR_THERMAL
> >>> tristate "Renesas R-Car thermal driver"
> >>> depends on ARCH_SHMOBILE || COMPILE_TEST
> >>> + depends on HAS_IO_MEM
> >>> help
> >>> Enable this to plug the R-Car thermal sensor driver into the Linux
> >>> thermal framework.
> >
> > I guess
> >
> > - HAS_IO_MEM
> > + HAS_IOMEM
>
> Yeah, this has been resolved in v2:
> https://lkml.org/lkml/2014/1/27/59

Nice !

Acked-by: Kuninori Morimoto <[email protected]>