touch: goodix: Sleep 100ms after reset operation
It is found there might be some i2c NACK error after power on and reset operation, from goodix datasheet it is required to wait 100ms after reset operation before I2C communication, so put a 100ms sleep after reset. Change-Id: I2601085f85c83a57bc895915506eaf0c29442678 Signed-off-by: Yu Wu <quic_zwy@quicinc.com>
This commit is contained in:
@@ -231,9 +231,12 @@ static int brl_power_on(struct goodix_ts_core *cd, bool on)
|
||||
goto power_off;
|
||||
}
|
||||
}
|
||||
|
||||
gpio_direction_output(cd->board_data.reset_gpio, 0);
|
||||
usleep_range(15000, 15100);
|
||||
gpio_direction_output(reset_gpio, 1);
|
||||
usleep_range(4000, 4100);
|
||||
gpio_direction_output(cd->board_data.reset_gpio, 1);
|
||||
msleep(GOODIX_NORMAL_RESET_DELAY_MS);
|
||||
|
||||
ret = brl_dev_confirm(cd);
|
||||
if (ret < 0)
|
||||
goto power_off;
|
||||
@@ -241,7 +244,6 @@ static int brl_power_on(struct goodix_ts_core *cd, bool on)
|
||||
if (ret < 0)
|
||||
goto power_off;
|
||||
|
||||
msleep(GOODIX_NORMAL_RESET_DELAY_MS);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user