ili9882_mmi: deep sleep update with gesture config

ili9882_mmi: need enter deep sleep when suspend
if gesture disable
NO_PROP_NEEDED

Change-Id: I9e1806b481e8eb7a803427b725745905336577ec
Signed-off-by: hujing3 <hujing3@lenovo.com>
Reviewed-on: https://gerrit.mot.com/1799686
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Xiangpo Zhao <zhaoxp3@motorola.com>
Submit-Approved: Jira Key
This commit is contained in:
hujing3 2020-11-11 18:25:37 +08:00 • committed by Jing Hu
commit f155ee5a66

View file

@ -443,6 +443,7 @@ static int ilitek_plat_notifier_fb(struct notifier_block *self, unsigned long ev
*/
if (event == DRM_PANEL_EARLY_EVENT_BLANK)
{
#if ENABLE_GESTURE
if (ilits->tp_module == MODEL_TM) {
if (ili_sleep_handler(TP_DEEP_SLEEP) < 0)
ILI_ERR("TP deep sleep in failed\n");
@ -450,6 +451,16 @@ static int ilitek_plat_notifier_fb(struct notifier_block *self, unsigned long ev
if (ili_sleep_handler(TP_SUSPEND) < 0)
ILI_ERR("TP suspend failed\n");
}
#else
//enter deep sleep when not enable gesture
if (ili_sleep_handler(TP_DEEP_SLEEP) < 0)
{
ILI_ERR("TP deep sleep in failed\n");
} else {
ILI_INFO("TP in deep sleep\n");
}
#endif
#ifdef ILI_CONFIG_GESTURE
touch_set_state(TOUCH_LOW_POWER_STATE, TOUCH_PANEL_IDX_PRIMARY);
#endif