From 1c72ae7c2ceeda86bf4937b2cd3edd5d4f581770 Mon Sep 17 00:00:00 2001 From: LiZidong Date: Tue, 15 Aug 2023 14:12:24 +0800 Subject: [PATCH] : Bangkok CSOT+FT3681 Fix TP Ghost Point Issue Fix unlocking with a fingerprint when the screen is off, ghost spots appear on the screen. No call to tp_gesture_recovery in tp_resume_recovery. Change-Id: I8f026cfb1faf35b11596dee7bd8ad561d5819cb1 Signed-off-by: LiZidong Reviewed-on: https://gerrit.mot.com/2720737 SLTApproved: Slta Waiver SME-Granted: SME Approvals Granted Tested-by: Jira Key Reviewed-by: Xiangpo Zhao Reviewed-by: Wei Deng Submit-Approved: Jira Key --- .../focaltech_touch_v3/focaltech_core.c | 14 ++++++++++++++ .../focaltech_touch_v3/focaltech_core.h | 1 + .../focaltech_touch_v3/focaltech_ts_mmi.c | 3 ++- 3 files changed, 17 insertions(+), 1 deletion(-) diff --git a/drivers/input/touchscreen/focaltech_touch_v3/focaltech_core.c b/drivers/input/touchscreen/focaltech_touch_v3/focaltech_core.c index 94b8f6f1fa0b..b192539dffda 100644 --- a/drivers/input/touchscreen/focaltech_touch_v3/focaltech_core.c +++ b/drivers/input/touchscreen/focaltech_touch_v3/focaltech_core.c @@ -156,6 +156,20 @@ void fts_tp_state_recovery(struct fts_ts_data *ts_data) FTS_FUNC_EXIT(); } +void fts_tp_resume_recovery(struct fts_ts_data *ts_data) +{ + FTS_FUNC_ENTER(); + /* wait tp stable */ + fts_wait_tp_to_valid(); + /* recover TP charger state 0x8B */ + /* recover TP glove state 0xC0 */ + /* recover TP cover state 0xC1 */ + fts_ex_mode_recovery(ts_data); + /* recover TP gesture state 0xD0 */ + //fts_gesture_recovery(ts_data); + FTS_FUNC_EXIT(); +} + int fts_reset_proc(int hdelayms) { FTS_DEBUG("tp reset"); diff --git a/drivers/input/touchscreen/focaltech_touch_v3/focaltech_core.h b/drivers/input/touchscreen/focaltech_touch_v3/focaltech_core.h index e741c9ddeeb6..ec3db7c2713b 100644 --- a/drivers/input/touchscreen/focaltech_touch_v3/focaltech_core.h +++ b/drivers/input/touchscreen/focaltech_touch_v3/focaltech_core.h @@ -417,6 +417,7 @@ int fts_check_cid(struct fts_ts_data *ts_data, u8 id_h); int fts_wait_tp_to_valid(void); void fts_release_all_finger(void); void fts_tp_state_recovery(struct fts_ts_data *ts_data); +void fts_tp_resume_recovery(struct fts_ts_data *ts_data); int fts_ex_mode_init(struct fts_ts_data *ts_data); int fts_ex_mode_exit(struct fts_ts_data *ts_data); int fts_ex_mode_recovery(struct fts_ts_data *ts_data); diff --git a/drivers/input/touchscreen/focaltech_touch_v3/focaltech_ts_mmi.c b/drivers/input/touchscreen/focaltech_touch_v3/focaltech_ts_mmi.c index 61d1cbe2c0a1..81208b517c27 100644 --- a/drivers/input/touchscreen/focaltech_touch_v3/focaltech_ts_mmi.c +++ b/drivers/input/touchscreen/focaltech_touch_v3/focaltech_ts_mmi.c @@ -727,7 +727,8 @@ static int fts_mmi_post_resume(struct device *dev) #endif } - fts_tp_state_recovery(ts_data); + //fts_tp_state_recovery(ts_data); + fts_tp_resume_recovery(ts_data); #if FTS_ESDCHECK_EN fts_esdcheck_resume();