* [PATCH] firmware: tegra-bpmp: mark PM function as __maybe_unused
@ 2018-10-02 21:21 Arnd Bergmann
2018-10-03 8:26 ` Jon Hunter
0 siblings, 1 reply; 7+ messages in thread
From: Arnd Bergmann @ 2018-10-02 21:21 UTC (permalink / raw)
To: Thierry Reding, Jonathan Hunter
Cc: Arnd Bergmann, Mikko Perttunen, Timo Alho, linux-tegra, linux-kernel
The newly added tegra_bpmp_resume function is unused when CONFIG_PM
is disabled:
drivers/firmware/tegra/bpmp.c:847:12: error: 'tegra_bpmp_resume' defined but not used [-Werror=unused-function]
static int tegra_bpmp_resume(struct device *dev)
Mark it as __maybe_unused to avoid the warning and let the compiler
drop it silently.
Fixes: cd40f6ff124c ("firmware: tegra: bpmp: Implement suspend/resume support")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
drivers/firmware/tegra/bpmp.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/firmware/tegra/bpmp.c b/drivers/firmware/tegra/bpmp.c
index 41448ba78be9..a3d5b518c10e 100644
--- a/drivers/firmware/tegra/bpmp.c
+++ b/drivers/firmware/tegra/bpmp.c
@@ -844,7 +844,7 @@ static int tegra_bpmp_probe(struct platform_device *pdev)
return err;
}
-static int tegra_bpmp_resume(struct device *dev)
+static int __maybe_unused tegra_bpmp_resume(struct device *dev)
{
struct tegra_bpmp *bpmp = dev_get_drvdata(dev);
unsigned int i;
--
2.18.0
^ permalink raw reply related [flat|nested] 7+ messages in thread
* Re: [PATCH] firmware: tegra-bpmp: mark PM function as __maybe_unused
2018-10-02 21:21 [PATCH] firmware: tegra-bpmp: mark PM function as __maybe_unused Arnd Bergmann
@ 2018-10-03 8:26 ` Jon Hunter
0 siblings, 0 replies; 7+ messages in thread
From: Jon Hunter @ 2018-10-03 8:26 UTC (permalink / raw)
To: Arnd Bergmann, Thierry Reding, Timo Alho
Cc: Mikko Perttunen, linux-tegra, linux-kernel
On 02/10/18 22:21, Arnd Bergmann wrote:
> The newly added tegra_bpmp_resume function is unused when CONFIG_PM
> is disabled:
>
> drivers/firmware/tegra/bpmp.c:847:12: error: 'tegra_bpmp_resume' defined but not used [-Werror=unused-function]
> static int tegra_bpmp_resume(struct device *dev)
>
> Mark it as __maybe_unused to avoid the warning and let the compiler
> drop it silently.
>
> Fixes: cd40f6ff124c ("firmware: tegra: bpmp: Implement suspend/resume support")
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> ---
> drivers/firmware/tegra/bpmp.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/firmware/tegra/bpmp.c b/drivers/firmware/tegra/bpmp.c
> index 41448ba78be9..a3d5b518c10e 100644
> --- a/drivers/firmware/tegra/bpmp.c
> +++ b/drivers/firmware/tegra/bpmp.c
> @@ -844,7 +844,7 @@ static int tegra_bpmp_probe(struct platform_device *pdev)
> return err;
> }
>
> -static int tegra_bpmp_resume(struct device *dev)
> +static int __maybe_unused tegra_bpmp_resume(struct device *dev)
> {
> struct tegra_bpmp *bpmp = dev_get_drvdata(dev);
> unsigned int i;
Arnd, is this seen with 32-bit ARM configs?
Timo, does it make sense to make BPMP dependent on ARCH_TEGRA_186_SOC
and ARCH_TEGRA_194_SOC instead of just ARCH_TEGRA? For 64-bit Tegra we
have a dependency on PM so this should not be seen for 64-bit Tegra.
Cheers
Jon
--
nvpublic
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] firmware: tegra-bpmp: mark PM function as __maybe_unused
@ 2018-10-03 8:26 ` Jon Hunter
0 siblings, 0 replies; 7+ messages in thread
From: Jon Hunter @ 2018-10-03 8:26 UTC (permalink / raw)
To: Arnd Bergmann, Thierry Reding, Timo Alho
Cc: Mikko Perttunen, linux-tegra, linux-kernel
On 02/10/18 22:21, Arnd Bergmann wrote:
> The newly added tegra_bpmp_resume function is unused when CONFIG_PM
> is disabled:
>
> drivers/firmware/tegra/bpmp.c:847:12: error: 'tegra_bpmp_resume' defined but not used [-Werror=unused-function]
> static int tegra_bpmp_resume(struct device *dev)
>
> Mark it as __maybe_unused to avoid the warning and let the compiler
> drop it silently.
>
> Fixes: cd40f6ff124c ("firmware: tegra: bpmp: Implement suspend/resume support")
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> ---
> drivers/firmware/tegra/bpmp.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/firmware/tegra/bpmp.c b/drivers/firmware/tegra/bpmp.c
> index 41448ba78be9..a3d5b518c10e 100644
> --- a/drivers/firmware/tegra/bpmp.c
> +++ b/drivers/firmware/tegra/bpmp.c
> @@ -844,7 +844,7 @@ static int tegra_bpmp_probe(struct platform_device *pdev)
> return err;
> }
>
> -static int tegra_bpmp_resume(struct device *dev)
> +static int __maybe_unused tegra_bpmp_resume(struct device *dev)
> {
> struct tegra_bpmp *bpmp = dev_get_drvdata(dev);
> unsigned int i;
Arnd, is this seen with 32-bit ARM configs?
Timo, does it make sense to make BPMP dependent on ARCH_TEGRA_186_SOC
and ARCH_TEGRA_194_SOC instead of just ARCH_TEGRA? For 64-bit Tegra we
have a dependency on PM so this should not be seen for 64-bit Tegra.
Cheers
Jon
--
nvpublic
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] firmware: tegra-bpmp: mark PM function as __maybe_unused
2018-10-03 8:26 ` Jon Hunter
(?)
@ 2018-10-04 15:11 ` Timo Alho
2018-10-04 15:31 ` Arnd Bergmann
-1 siblings, 1 reply; 7+ messages in thread
From: Timo Alho @ 2018-10-04 15:11 UTC (permalink / raw)
To: Jonathan Hunter, Arnd Bergmann, Thierry Reding
Cc: Mikko Perttunen, linux-tegra, linux-kernel
On 03.10.2018 11:26, Jonathan Hunter wrote:
>
> On 02/10/18 22:21, Arnd Bergmann wrote:
>> The newly added tegra_bpmp_resume function is unused when CONFIG_PM
>> is disabled:
>>
>> drivers/firmware/tegra/bpmp.c:847:12: error: 'tegra_bpmp_resume' defined but not used [-Werror=unused-function]
>> static int tegra_bpmp_resume(struct device *dev)
>>
>> Mark it as __maybe_unused to avoid the warning and let the compiler
>> drop it silently.
>>
>> Fixes: cd40f6ff124c ("firmware: tegra: bpmp: Implement suspend/resume support")
>> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
>> ---
>> drivers/firmware/tegra/bpmp.c | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/drivers/firmware/tegra/bpmp.c b/drivers/firmware/tegra/bpmp.c
>> index 41448ba78be9..a3d5b518c10e 100644
>> --- a/drivers/firmware/tegra/bpmp.c
>> +++ b/drivers/firmware/tegra/bpmp.c
>> @@ -844,7 +844,7 @@ static int tegra_bpmp_probe(struct platform_device *pdev)
>> return err;
>> }
>>
>> -static int tegra_bpmp_resume(struct device *dev)
>> +static int __maybe_unused tegra_bpmp_resume(struct device *dev)
>> {
>> struct tegra_bpmp *bpmp = dev_get_drvdata(dev);
>> unsigned int i;
>
> Arnd, is this seen with 32-bit ARM configs?
>
> Timo, does it make sense to make BPMP dependent on ARCH_TEGRA_186_SOC
> and ARCH_TEGRA_194_SOC instead of just ARCH_TEGRA? For 64-bit Tegra we
> have a dependency on PM so this should not be seen for 64-bit Tegra.
Jon, there will be eventually a BPMP driver for ARCH_TEGRA_210_SOC as
well. So it is probably more appropriate to make BPMP dependent on ARM64
& ARCH_TEGRA.
-Timo
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] firmware: tegra-bpmp: mark PM function as __maybe_unused
2018-10-04 15:11 ` Timo Alho
@ 2018-10-04 15:31 ` Arnd Bergmann
2018-10-04 16:19 ` Jon Hunter
0 siblings, 1 reply; 7+ messages in thread
From: Arnd Bergmann @ 2018-10-04 15:31 UTC (permalink / raw)
To: talho
Cc: Jonathan Hunter, Thierry Reding, Mikko Perttunen,
open list:TEGRA ARCHITECTURE SUPPORT, Linux Kernel Mailing List
On Thu, Oct 4, 2018 at 5:11 PM Timo Alho <talho@nvidia.com> wrote:
> On 03.10.2018 11:26, Jonathan Hunter wrote:
> > On 02/10/18 22:21, Arnd Bergmann wrote:
> >> The newly added tegra_bpmp_resume function is unused when CONFIG_PM
> >> is disabled:
> >>
> >> drivers/firmware/tegra/bpmp.c:847:12: error: 'tegra_bpmp_resume' defined but not used [-Werror=unused-function]
> >> static int tegra_bpmp_resume(struct device *dev)
> >>
> >> Mark it as __maybe_unused to avoid the warning and let the compiler
> >> drop it silently.
> >>
> >> Fixes: cd40f6ff124c ("firmware: tegra: bpmp: Implement suspend/resume support")
> >> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> >> ---
> >> drivers/firmware/tegra/bpmp.c | 2 +-
> >> 1 file changed, 1 insertion(+), 1 deletion(-)
> >>
> >> diff --git a/drivers/firmware/tegra/bpmp.c b/drivers/firmware/tegra/bpmp.c
> >> index 41448ba78be9..a3d5b518c10e 100644
> >> --- a/drivers/firmware/tegra/bpmp.c
> >> +++ b/drivers/firmware/tegra/bpmp.c
> >> @@ -844,7 +844,7 @@ static int tegra_bpmp_probe(struct platform_device *pdev)
> >> return err;
> >> }
> >>
> >> -static int tegra_bpmp_resume(struct device *dev)
> >> +static int __maybe_unused tegra_bpmp_resume(struct device *dev)
> >> {
> >> struct tegra_bpmp *bpmp = dev_get_drvdata(dev);
> >> unsigned int i;
> >
> > Arnd, is this seen with 32-bit ARM configs?
This was with a randconfig build on 64-bit ARM. I don't know exactly
what combination of options caused it.
> > Timo, does it make sense to make BPMP dependent on ARCH_TEGRA_186_SOC
> > and ARCH_TEGRA_194_SOC instead of just ARCH_TEGRA? For 64-bit Tegra we
> > have a dependency on PM so this should not be seen for 64-bit Tegra.
CONFIG_PM does not imply CONFIG_PM_SLEEP, so probably it
was just broken for PM=y, PM_SLEEP=n.
> Jon, there will be eventually a BPMP driver for ARCH_TEGRA_210_SOC as
> well. So it is probably more appropriate to make BPMP dependent on ARM64
> & ARCH_TEGRA.
Generally speaking, we are trying to allow building all drivers at least
with CONFIG_COMPILE_TEST, in order to get the best build coverage.
Arnd
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] firmware: tegra-bpmp: mark PM function as __maybe_unused
2018-10-04 15:31 ` Arnd Bergmann
@ 2018-10-04 16:19 ` Jon Hunter
0 siblings, 0 replies; 7+ messages in thread
From: Jon Hunter @ 2018-10-04 16:19 UTC (permalink / raw)
To: Arnd Bergmann, talho
Cc: Thierry Reding, Mikko Perttunen,
open list:TEGRA ARCHITECTURE SUPPORT, Linux Kernel Mailing List
On 04/10/18 16:31, Arnd Bergmann wrote:
> On Thu, Oct 4, 2018 at 5:11 PM Timo Alho <talho@nvidia.com> wrote:
>> On 03.10.2018 11:26, Jonathan Hunter wrote:
>>> On 02/10/18 22:21, Arnd Bergmann wrote:
>>>> The newly added tegra_bpmp_resume function is unused when CONFIG_PM
>>>> is disabled:
>>>>
>>>> drivers/firmware/tegra/bpmp.c:847:12: error: 'tegra_bpmp_resume' defined but not used [-Werror=unused-function]
>>>> static int tegra_bpmp_resume(struct device *dev)
>>>>
>>>> Mark it as __maybe_unused to avoid the warning and let the compiler
>>>> drop it silently.
>>>>
>>>> Fixes: cd40f6ff124c ("firmware: tegra: bpmp: Implement suspend/resume support")
>>>> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
>>>> ---
>>>> drivers/firmware/tegra/bpmp.c | 2 +-
>>>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>>>
>>>> diff --git a/drivers/firmware/tegra/bpmp.c b/drivers/firmware/tegra/bpmp.c
>>>> index 41448ba78be9..a3d5b518c10e 100644
>>>> --- a/drivers/firmware/tegra/bpmp.c
>>>> +++ b/drivers/firmware/tegra/bpmp.c
>>>> @@ -844,7 +844,7 @@ static int tegra_bpmp_probe(struct platform_device *pdev)
>>>> return err;
>>>> }
>>>>
>>>> -static int tegra_bpmp_resume(struct device *dev)
>>>> +static int __maybe_unused tegra_bpmp_resume(struct device *dev)
>>>> {
>>>> struct tegra_bpmp *bpmp = dev_get_drvdata(dev);
>>>> unsigned int i;
>>>
>>> Arnd, is this seen with 32-bit ARM configs?
>
> This was with a randconfig build on 64-bit ARM. I don't know exactly
> what combination of options caused it.
>
>>> Timo, does it make sense to make BPMP dependent on ARCH_TEGRA_186_SOC
>>> and ARCH_TEGRA_194_SOC instead of just ARCH_TEGRA? For 64-bit Tegra we
>>> have a dependency on PM so this should not be seen for 64-bit Tegra.
>
> CONFIG_PM does not imply CONFIG_PM_SLEEP, so probably it
> was just broken for PM=y, PM_SLEEP=n.
Yes that would make sense.
>> Jon, there will be eventually a BPMP driver for ARCH_TEGRA_210_SOC as
>> well. So it is probably more appropriate to make BPMP dependent on ARM64
>> & ARCH_TEGRA.
>
> Generally speaking, we are trying to allow building all drivers at least
> with CONFIG_COMPILE_TEST, in order to get the best build coverage.
True. Thinking some more it is fine with me, so ...
Acked-by: Jon Hunter <jonathanh@nvidia.com>
Cheers
Jon
--
nvpublic
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] firmware: tegra-bpmp: mark PM function as __maybe_unused
@ 2018-10-04 16:19 ` Jon Hunter
0 siblings, 0 replies; 7+ messages in thread
From: Jon Hunter @ 2018-10-04 16:19 UTC (permalink / raw)
To: Arnd Bergmann, talho
Cc: Thierry Reding, Mikko Perttunen,
open list:TEGRA ARCHITECTURE SUPPORT, Linux Kernel Mailing List
On 04/10/18 16:31, Arnd Bergmann wrote:
> On Thu, Oct 4, 2018 at 5:11 PM Timo Alho <talho@nvidia.com> wrote:
>> On 03.10.2018 11:26, Jonathan Hunter wrote:
>>> On 02/10/18 22:21, Arnd Bergmann wrote:
>>>> The newly added tegra_bpmp_resume function is unused when CONFIG_PM
>>>> is disabled:
>>>>
>>>> drivers/firmware/tegra/bpmp.c:847:12: error: 'tegra_bpmp_resume' defined but not used [-Werror=unused-function]
>>>> static int tegra_bpmp_resume(struct device *dev)
>>>>
>>>> Mark it as __maybe_unused to avoid the warning and let the compiler
>>>> drop it silently.
>>>>
>>>> Fixes: cd40f6ff124c ("firmware: tegra: bpmp: Implement suspend/resume support")
>>>> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
>>>> ---
>>>> drivers/firmware/tegra/bpmp.c | 2 +-
>>>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>>>
>>>> diff --git a/drivers/firmware/tegra/bpmp.c b/drivers/firmware/tegra/bpmp.c
>>>> index 41448ba78be9..a3d5b518c10e 100644
>>>> --- a/drivers/firmware/tegra/bpmp.c
>>>> +++ b/drivers/firmware/tegra/bpmp.c
>>>> @@ -844,7 +844,7 @@ static int tegra_bpmp_probe(struct platform_device *pdev)
>>>> return err;
>>>> }
>>>>
>>>> -static int tegra_bpmp_resume(struct device *dev)
>>>> +static int __maybe_unused tegra_bpmp_resume(struct device *dev)
>>>> {
>>>> struct tegra_bpmp *bpmp = dev_get_drvdata(dev);
>>>> unsigned int i;
>>>
>>> Arnd, is this seen with 32-bit ARM configs?
>
> This was with a randconfig build on 64-bit ARM. I don't know exactly
> what combination of options caused it.
>
>>> Timo, does it make sense to make BPMP dependent on ARCH_TEGRA_186_SOC
>>> and ARCH_TEGRA_194_SOC instead of just ARCH_TEGRA? For 64-bit Tegra we
>>> have a dependency on PM so this should not be seen for 64-bit Tegra.
>
> CONFIG_PM does not imply CONFIG_PM_SLEEP, so probably it
> was just broken for PM=y, PM_SLEEP=n.
Yes that would make sense.
>> Jon, there will be eventually a BPMP driver for ARCH_TEGRA_210_SOC as
>> well. So it is probably more appropriate to make BPMP dependent on ARM64
>> & ARCH_TEGRA.
>
> Generally speaking, we are trying to allow building all drivers at least
> with CONFIG_COMPILE_TEST, in order to get the best build coverage.
True. Thinking some more it is fine with me, so ...
Acked-by: Jon Hunter <jonathanh@nvidia.com>
Cheers
Jon
--
nvpublic
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2018-10-04 16:20 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-10-02 21:21 [PATCH] firmware: tegra-bpmp: mark PM function as __maybe_unused Arnd Bergmann
2018-10-03 8:26 ` Jon Hunter
2018-10-03 8:26 ` Jon Hunter
2018-10-04 15:11 ` Timo Alho
2018-10-04 15:31 ` Arnd Bergmann
2018-10-04 16:19 ` Jon Hunter
2018-10-04 16:19 ` Jon Hunter
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.