From f276ef5e12519db650fe3c9223cf0c55f00faecf Mon Sep 17 00:00:00 2001 From: Wendly Li Date: Mon, 17 Apr 2023 14:20:42 +0000 Subject: touch/goodix: Fix deadlock between irq and wakelock Bug: 289696186 Test: Check touch works properly Change-Id: I91f64e48efd67bdabaa64134e8e395a351d23728 Signed-off-by: Wendly Li --- goodix_ts_core.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/goodix_ts_core.c b/goodix_ts_core.c index b4a8c7f..e42836c 100644 --- a/goodix_ts_core.c +++ b/goodix_ts_core.c @@ -2672,7 +2672,11 @@ static int goodix_ts_resume(struct goodix_ts_core *core_data) goodix_set_pinctrl_state(core_data, PINCTRL_MODE_ACTIVE); atomic_set(&core_data->suspended, 0); - hw_ops->irq_enable(core_data, false); + /* [GOOG] + * This will cause a deadlock with wakelock. Since we already disable irq + * when touch is suspended, we don't need to disable irq here again. + */ + //hw_ops->irq_enable(core_data, false); mutex_lock(&goodix_modules.mutex); if (!list_empty(&goodix_modules.head)) { -- cgit v1.2.3