* [PATCH] Input: pf1550 - convert to DEFINE_SIMPLE_DEV_PM_OPS
@ 2025-12-04 10:04 Arnd Bergmann
0 siblings, 0 replies; only message in thread
From: Arnd Bergmann @ 2025-12-04 10:04 UTC (permalink / raw)
To: Samuel Kayode, Dmitry Torokhov, Frank Li, Lee Jones
Cc: Arnd Bergmann, imx, linux-input, linux-kernel
From: Arnd Bergmann <arnd@arndb.de>
SIMPLE_DEV_PM_OPS() is deprecated and used incorrectly in this new
driver:
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)
| ^~~~~~~~~~~~~~~~~~~~
Convert to the modern DEFINE_SIMPLE_DEV_PM_OPS() that avoids these warnings.
Fixes: 9acb215cbebd ("Input: pf1550 - add onkey support")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
drivers/input/misc/pf1550-onkey.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/input/misc/pf1550-onkey.c b/drivers/input/misc/pf1550-onkey.c
index 9be6377151cb..a636ceedfc04 100644
--- a/drivers/input/misc/pf1550-onkey.c
+++ b/drivers/input/misc/pf1550-onkey.c
@@ -173,8 +173,8 @@ static int pf1550_onkey_resume(struct device *dev)
return 0;
}
-static SIMPLE_DEV_PM_OPS(pf1550_onkey_pm_ops, pf1550_onkey_suspend,
- pf1550_onkey_resume);
+static DEFINE_SIMPLE_DEV_PM_OPS(pf1550_onkey_pm_ops, pf1550_onkey_suspend,
+ pf1550_onkey_resume);
static const struct platform_device_id pf1550_onkey_id[] = {
{ "pf1550-onkey", },
--
2.39.5
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2025-12-04 10:04 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-12-04 10:04 [PATCH] Input: pf1550 - convert to DEFINE_SIMPLE_DEV_PM_OPS Arnd Bergmann
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).