author | Yingyuan Zhu <yingyuan.zhu@amlogic.com> | 2018-10-26 12:14:06 (GMT) |
---|---|---|
committer | Can Cao <can.cao@amlogic.com> | 2018-10-29 09:26:09 (GMT) |
commit | 66e1de527b6ab92baca109dcdcc9349724952add (patch) | |
tree | 270bc7a4e14f25ce158c49973ada4dba99e18edd | |
parent | e6409ed23a71555615a14db5845590163ebc5dff (diff) | |
download | common-66e1de527b6ab92baca109dcdcc9349724952add.zip common-66e1de527b6ab92baca109dcdcc9349724952add.tar.gz common-66e1de527b6ab92baca109dcdcc9349724952add.tar.bz2 |
adc_key: delete early_suspend code [1/1]
PD#OTT-144
Problem:
after the dark screen, the adc button does not work
Solution:
The adc_keypad introduces earlysuspend for MID project:
after the LCD backlight disable, prevent the user from
pressing the key to open some applications and not complete standby.
Now check the adc button using the "system_freezable_wq" system queue,
which replaces the function of the code.So can remove it.
Verify:
g12b socket
Change-Id: I2333ba3dc406d2624962d116293a0b9d36f97534
Signed-off-by: Yingyuan Zhu <yingyuan.zhu@amlogic.com>
-rw-r--r-- | drivers/amlogic/input/keyboard/adc_keypad.c | 30 |
1 files changed, 1 insertions, 29 deletions
diff --git a/drivers/amlogic/input/keyboard/adc_keypad.c b/drivers/amlogic/input/keyboard/adc_keypad.c index 0b9f7af..432aebf 100644 --- a/drivers/amlogic/input/keyboard/adc_keypad.c +++ b/drivers/amlogic/input/keyboard/adc_keypad.c @@ -100,25 +100,6 @@ static void meson_adc_kp_poll(struct input_polled_dev *dev) } -#ifdef CONFIG_AMLOGIC_LEGACY_EARLY_SUSPEND -static void meson_adc_kp_early_suspend(struct early_suspend *h) -{ - struct meson_adc_kp *kp = container_of(h, - struct meson_adc_kp, early_suspend); - - cancel_delayed_work_sync(&kp->poll_dev->work); -} - -static void meson_adc_kp_late_resume(struct early_suspend *h) -{ - struct meson_adc_kp *kp = container_of(h, - struct meson_adc_kp, early_suspend); - - queue_delayed_work(system_freezable_wq, &kp->poll_dev->work, - msecs_to_jiffies(kp->poll_dev->poll_interval)); -} -#endif - static void send_data_to_bl301(void) { u32 val; @@ -553,13 +534,6 @@ static int meson_adc_kp_probe(struct platform_device *pdev) input->keycodesize = sizeof(unsigned short); input->keycodemax = 0x1ff; -#ifdef CONFIG_AMLOGIC_LEGACY_EARLY_SUSPEND - kp->early_suspend.level = EARLY_SUSPEND_LEVEL_BLANK_SCREEN; - kp->early_suspend.suspend = meson_adc_kp_early_suspend; - kp->early_suspend.resume = meson_adc_kp_late_resume; - register_early_suspend(&kp->early_suspend); -#endif - /*init class*/ kp->kp_class.name = DRIVE_NAME; kp->kp_class.owner = THIS_MODULE; @@ -593,9 +567,7 @@ static int meson_adc_kp_remove(struct platform_device *pdev) struct meson_adc_kp *kp = platform_get_drvdata(pdev); class_unregister(&kp->kp_class); -#ifdef CONFIG_AMLOGIC_LEGACY_EARLY_SUSPEND - unregister_early_suspend(&kp->early_suspend); -#endif + cancel_delayed_work(&kp->poll_dev->work); meson_adc_kp_list_free(kp); kfree(kp); return 0; |