aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/input/touchscreen
diff options
context:
space:
mode:
authorHungNien Chen <hn.chen@weidahitech.com>2015-07-11 17:30:19 -0700
committerDmitry Torokhov <dmitry.torokhov@gmail.com>2015-07-11 23:26:33 -0700
commit339d6b88e872f8369495a7224916a4d1d8376ca3 (patch)
treeb10b9fe6351ed168da7b4b8238826da148c24507 /drivers/input/touchscreen
parentInput: wdt87xx_i2c - populate vendor and product in input device (diff)
downloadlinux-dev-339d6b88e872f8369495a7224916a4d1d8376ca3.tar.xz
linux-dev-339d6b88e872f8369495a7224916a4d1d8376ca3.zip
Input: wdt87xx_i2c - change the sleep time to 2500ms after the sw reset
The original wait time was 200ms which was enough for the firmware to finish loading and boot. After that the firmware will perform initialization and touch calibration, which will take about 1.1 second. The touch calibration will change controller frequency to scan at the most optimal frequency and during calibration/frequency switching process we may run into i2c data errors. To avoid them we extend the sleep to 2500ms after issuing the sw reset. Signed-off-by: HungNien Chen <hn.chen@weidahitech.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Diffstat (limited to 'drivers/input/touchscreen')
-rw-r--r--drivers/input/touchscreen/wdt87xx_i2c.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/input/touchscreen/wdt87xx_i2c.c b/drivers/input/touchscreen/wdt87xx_i2c.c
index 764d8f28203c..515c20a6e10f 100644
--- a/drivers/input/touchscreen/wdt87xx_i2c.c
+++ b/drivers/input/touchscreen/wdt87xx_i2c.c
@@ -157,6 +157,7 @@
/* Controller requires minimum 300us between commands */
#define WDT_COMMAND_DELAY_MS 2
#define WDT_FLASH_WRITE_DELAY_MS 4
+#define WDT_FW_RESET_TIME 2500
struct wdt87xx_sys_param {
u16 fw_id;
@@ -406,7 +407,7 @@ static int wdt87xx_sw_reset(struct i2c_client *client)
}
/* Wait the device to be ready */
- msleep(200);
+ msleep(WDT_FW_RESET_TIME);
return 0;
}