public inbox for linux-input@vger.kernel.org
 help / color / mirror / Atom feed
* [patch 1/1] drivers/input/misc/pf1550-onkey.c: fix build with CONFIG_PM_SLEEP=n
@ 2026-02-14  0:38 Andrew Morton
  2026-02-14  2:56 ` Dmitry Torokhov
  0 siblings, 1 reply; 2+ messages in thread
From: Andrew Morton @ 2026-02-14  0:38 UTC (permalink / raw)
  To: sean, Frank.Li, akpm, linux-input, samuel.kayode, dmitry.torokhov,
	akpm

From: Andrew Morton <akpm@linux-foundation.org>
Subject: drivers/input/misc/pf1550-onkey.c: fix build with CONFIG_PM_SLEEP=n
Date: Fri Feb 13 02:39:04 PM PST 2026

riscv randconfig:

drivers/input/misc/pf1550-onkey.c:154:12: error: 'pf1550_onkey_resume' defined but not used [-Werror=unused-function]
  154 | static int pf1550_onkey_resume(struct device *dev)
      |            ^~~~~~~~~~~~~~~~~~~
drivers/input/misc/pf1550-onkey.c:133:12: error: 'pf1550_onkey_suspend' defined but not used [-Werror=unused-function]
  133 | static int pf1550_onkey_suspend(struct device *dev)
      |            ^~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors

Cc: Samuel Kayode <samuel.kayode@savoirfairelinux.com>
Cc: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Cc: Frank Li <Frank.Li@nxp.com>
Cc: Sean Nyekjaer <sean@geanix.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---

 drivers/input/misc/pf1550-onkey.c |    2 ++
 1 file changed, 2 insertions(+)

--- a/drivers/input/misc/pf1550-onkey.c~drivers-input-misc-pf1550-onkeyc-fix-build-with-config_pm_sleep=n
+++ a/drivers/input/misc/pf1550-onkey.c
@@ -130,6 +130,7 @@ static int pf1550_onkey_probe(struct pla
 	return 0;
 }
 
+#ifdef CONFIG_PM_SLEEP
 static int pf1550_onkey_suspend(struct device *dev)
 {
 	struct platform_device *pdev = to_platform_device(dev);
@@ -175,6 +176,7 @@ static int pf1550_onkey_resume(struct de
 
 static SIMPLE_DEV_PM_OPS(pf1550_onkey_pm_ops, pf1550_onkey_suspend,
 			 pf1550_onkey_resume);
+#endif CONFIG_PM_SLEEP
 
 static const struct platform_device_id pf1550_onkey_id[] = {
 	{ "pf1550-onkey", },
_

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

* Re: [patch 1/1] drivers/input/misc/pf1550-onkey.c: fix build with CONFIG_PM_SLEEP=n
  2026-02-14  0:38 [patch 1/1] drivers/input/misc/pf1550-onkey.c: fix build with CONFIG_PM_SLEEP=n Andrew Morton
@ 2026-02-14  2:56 ` Dmitry Torokhov
  0 siblings, 0 replies; 2+ messages in thread
From: Dmitry Torokhov @ 2026-02-14  2:56 UTC (permalink / raw)
  To: Andrew Morton; +Cc: sean, Frank.Li, linux-input, samuel.kayode

Hi Andrew,

On Fri, Feb 13, 2026 at 04:38:28PM -0800, Andrew Morton wrote:
> From: Andrew Morton <akpm@linux-foundation.org>
> Subject: drivers/input/misc/pf1550-onkey.c: fix build with CONFIG_PM_SLEEP=n
> Date: Fri Feb 13 02:39:04 PM PST 2026
> 
> riscv randconfig:
> 
> drivers/input/misc/pf1550-onkey.c:154:12: error: 'pf1550_onkey_resume' defined but not used [-Werror=unused-function]
>   154 | static int pf1550_onkey_resume(struct device *dev)
>       |            ^~~~~~~~~~~~~~~~~~~
> drivers/input/misc/pf1550-onkey.c:133:12: error: 'pf1550_onkey_suspend' defined but not used [-Werror=unused-function]
>   133 | static int pf1550_onkey_suspend(struct device *dev)
>       |            ^~~~~~~~~~~~~~~~~~~~
> cc1: all warnings being treated as errors

Picked the following fix for this:

https://patch.msgid.link/20251210211149.543928-1-vaibhavgupta40@gmail.com

Thanks.

-- 
Dmitry

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

end of thread, other threads:[~2026-02-14  2:56 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-02-14  0:38 [patch 1/1] drivers/input/misc/pf1550-onkey.c: fix build with CONFIG_PM_SLEEP=n Andrew Morton
2026-02-14  2:56 ` Dmitry Torokhov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox