Re: [PATCH 1/2] mfd: max14577: max14577_{suspend,resume}() shoulddepend on CONFIG_PM_SLEEP
From: Geert Uytterhoeven
Date: Mon Jan 27 2014 - 03:31:29 EST
On Mon, Jan 27, 2014 at 9:28 AM, Krzysztof Kozlowski
<k.kozlowski@xxxxxxxxxxx> wrote:
> On Sun, 2014-01-26 at 11:38 +0100, Geert Uytterhoeven wrote:
>> If CONFIG_PM_SLEEP=n:
>>
>> drivers/mfd/max14577.c:177: warning: âmax14577_suspendâ defined but not used
>> drivers/mfd/max14577.c:200: warning: âmax14577_resumeâ defined but not used
>>
>> Signed-off-by: Geert Uytterhoeven <geert@xxxxxxxxxxxxxx>
>> ---
>> drivers/mfd/max14577.c | 2 ++
>> 1 file changed, 2 insertions(+)
>>
>> diff --git a/drivers/mfd/max14577.c b/drivers/mfd/max14577.c
>> index ac514fb2b877..71aa14a6bfbb 100644
>> --- a/drivers/mfd/max14577.c
>> +++ b/drivers/mfd/max14577.c
>> @@ -173,6 +173,7 @@ static const struct i2c_device_id max14577_i2c_id[] = {
>> };
>> MODULE_DEVICE_TABLE(i2c, max14577_i2c_id);
>>
>> +#ifdef CONFIG_PM_SLEEP
>> static int max14577_suspend(struct device *dev)
>> {
>> struct i2c_client *i2c = container_of(dev, struct i2c_client, dev);
>> @@ -208,6 +209,7 @@ static int max14577_resume(struct device *dev)
>>
>> return 0;
>> }
>> +#endif /* CONFIG_PM_SLEEP */
>>
>> static struct of_device_id max14577_dt_match[] = {
>> { .compatible = "maxim,max14577", },
>
> Same here:
> http://thread.gmane.org/gmane.linux.kernel/1615513/focus=1615563
> although I don't mind if your patch comes in :).
Sorry, missed those.
It's a pity these known fixes don't go in together with the code that introduces
them...
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@xxxxxxxxxxxxxx
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/