From f7482af5df4833661ad0b82a798118da2e1c1767 Mon Sep 17 00:00:00 2001 From: hq_caoqunhui_tmp Date: Sat, 8 Oct 2022 15:09:47 +0800 Subject: [PATCH] Add the recovery scheme of the secondary panel ESD software Modify: Add the recovery scheme of the secondary panel ESD softwaret Change-Id: I28972b42e5331d7b69224e68d1f50f45f06aeeaf Reviewed-on: https://gerrit.mot.com/2399011 Reviewed-by: Wei Deng SME-Granted: SME Approvals Granted SLTApproved: Slta Waiver Tested-by: Jira Key Reviewed-by: Xiangpo Zhao Submit-Approved: Jira Key --- .../focaltech_0flash_v2_mmi/focaltech_ex_fun.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/drivers/input/touchscreen/focaltech_0flash_v2_mmi/focaltech_ex_fun.c b/drivers/input/touchscreen/focaltech_0flash_v2_mmi/focaltech_ex_fun.c index 3b7a4920cdbf..84138f7c9dfe 100644 --- a/drivers/input/touchscreen/focaltech_0flash_v2_mmi/focaltech_ex_fun.c +++ b/drivers/input/touchscreen/focaltech_0flash_v2_mmi/focaltech_ex_fun.c @@ -871,9 +871,12 @@ static ssize_t fts_ic_ver_show(struct device *dev, int count = 0; u8 val = 0; struct input_dev *input_dev = fts_data->input_dev; +#if FTS_ESDCHECK_EN + struct fts_ts_data *data = fts_data; +#endif mutex_lock(&input_dev->mutex); #if FTS_ESDCHECK_EN - fts_esdcheck_proc_busy(1); + fts_esdcheck_proc_busy(data, 1); #endif fts_read_reg(FTS_REG_VENDOR_ID, &val); count += snprintf(buf + count, PAGE_SIZE, "Product ID: 0x%02x\n", val); @@ -881,7 +884,7 @@ static ssize_t fts_ic_ver_show(struct device *dev, count += snprintf(buf + count, PAGE_SIZE, "Build ID: 0000-%02x\n", val); count += scnprintf(buf + count, PAGE_SIZE, "IC: %s\n", FTS_CHIP_NAME); #if FTS_ESDCHECK_EN - fts_esdcheck_proc_busy(0); + fts_esdcheck_proc_busy(data, 0); #endif mutex_unlock(&input_dev->mutex); return count; @@ -933,11 +936,11 @@ static ssize_t buildid_show( mutex_lock(&input_dev->mutex); #if FTS_ESDCHECK_EN - fts_esdcheck_proc_busy(1); + fts_esdcheck_proc_busy(ts_data, 1); #endif fts_read_reg(FTS_REG_FW_VER, &fwver); #if FTS_ESDCHECK_EN - fts_esdcheck_proc_busy(0); + fts_esdcheck_proc_busy(ts_data, 0); #endif if ((fwver == 0xFF) || (fwver == 0x00)) num_read_chars = snprintf(buf, PAGE_SIZE, "get tp fw version fail!\n");