Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

Input: nomadik-ske-keypad - convert to using SIMPLE_DEV_PM_OPS

Also proper guard for system suspend/resume methods is CONFIG_PM_SLEEP,
not CONFIG_PM.

Acked-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>

+4 -8
+4 -8
drivers/input/keyboard/nomadik-ske-keypad.c
··· 344 344 return 0; 345 345 } 346 346 347 - #ifdef CONFIG_PM 347 + #ifdef CONFIG_PM_SLEEP 348 348 static int ske_keypad_suspend(struct device *dev) 349 349 { 350 350 struct platform_device *pdev = to_platform_device(dev); ··· 372 372 373 373 return 0; 374 374 } 375 - 376 - static const struct dev_pm_ops ske_keypad_dev_pm_ops = { 377 - .suspend = ske_keypad_suspend, 378 - .resume = ske_keypad_resume, 379 - }; 380 375 #endif 376 + 377 + static SIMPLE_DEV_PM_OPS(ske_keypad_dev_pm_ops, 378 + ske_keypad_suspend, ske_keypad_resume); 381 379 382 380 static struct platform_driver ske_keypad_driver = { 383 381 .driver = { 384 382 .name = "nmk-ske-keypad", 385 383 .owner = THIS_MODULE, 386 - #ifdef CONFIG_PM 387 384 .pm = &ske_keypad_dev_pm_ops, 388 - #endif 389 385 }, 390 386 .remove = __devexit_p(ske_keypad_remove), 391 387 };