From ac7db4fdec4aaa5462f56779274b4bf265a2f948 Mon Sep 17 00:00:00 2001 From: litong20 Date: Wed, 21 Jul 2021 13:53:42 +0800 Subject: [PATCH] put register_panel_notifier into ts_mmi_worker_func. When there is no need to find the active panel, that is, the panel_status is always 0, register panel notifier normally. Change-Id: I2aef34a1fd7ca310bf1fc6a4d9501413208d14c9 Reviewed-on: https://gerrit.mot.com/2019893 SME-Granted: SME Approvals Granted SLTApproved: Slta Waiver Tested-by: Jira Key Reviewed-by: Jichao Zou Submit-Approved: Jira Key --- .../touchscreen/touchscreen_mmi/touchscreen_mmi_notif.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/input/touchscreen/touchscreen_mmi/touchscreen_mmi_notif.c b/drivers/input/touchscreen/touchscreen_mmi/touchscreen_mmi_notif.c index 68514de5395f..9086ead3e673 100644 --- a/drivers/input/touchscreen/touchscreen_mmi/touchscreen_mmi_notif.c +++ b/drivers/input/touchscreen/touchscreen_mmi/touchscreen_mmi_notif.c @@ -353,12 +353,12 @@ static void ts_mmi_worker_func(struct work_struct *w) if (ret < 0) { dev_err(DEV_TS, "%s: check drm panel failed. %d\n", __func__, ret); touch_cdev->panel_status = -1; - } else { - touch_cdev->panel_status = 0; - dev_info(DEV_MMI, "%s: register panel notifier\n", __func__); - REGISTER_PANEL_NOTIFIER; } #endif + if (!touch_cdev->panel_status) { + REGISTER_PANEL_NOTIFIER; + dev_info(DEV_MMI, "%s: register panel notifier\n", __func__); + } break; default: