Input: pf1550 - convert to DEFINE_SIMPLE_DEV_PM_OPS
Subsystems (4)
PATCH 1/1 Input: pf1550 - convert to DEFINE_SIMPLE_DEV_PM_OPS
From: Arnd Bergmann <[email protected]>
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 <[email protected]>
--- drivers/input/misc/pf1550-onkey.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/input/misc/pf1550-onkey.c +2 -2
@@ -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" , },
Signature · 1 line
2.39.5