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

Input: samsung-keypad - switch to using SIMPLE_DEV_PM_OPS

Signed-off-by: Dmitry Torokhov <dtor@mail.ru>

+4 -8
+4 -8
drivers/input/keyboard/samsung-keypad.c
··· 381 381 return 0; 382 382 } 383 383 384 - #ifdef CONFIG_PM 384 + #ifdef CONFIG_PM_SLEEP 385 385 static void samsung_keypad_toggle_wakeup(struct samsung_keypad *keypad, 386 386 bool enable) 387 387 { ··· 440 440 441 441 return 0; 442 442 } 443 - 444 - static const struct dev_pm_ops samsung_keypad_pm_ops = { 445 - .suspend = samsung_keypad_suspend, 446 - .resume = samsung_keypad_resume, 447 - }; 448 443 #endif 444 + 445 + static SIMPLE_DEV_PM_OPS(samsung_keypad_pm_ops, 446 + samsung_keypad_suspend, samsung_keypad_resume); 449 447 450 448 static struct platform_device_id samsung_keypad_driver_ids[] = { 451 449 { ··· 463 465 .driver = { 464 466 .name = "samsung-keypad", 465 467 .owner = THIS_MODULE, 466 - #ifdef CONFIG_PM 467 468 .pm = &samsung_keypad_pm_ops, 468 - #endif 469 469 }, 470 470 .id_table = samsung_keypad_driver_ids, 471 471 };