From 080b0dfd26afab4e4726778e381070ad0ec255bd Mon Sep 17 00:00:00 2001 From: djung Date: Tue, 24 Jun 2014 14:08:36 -0700 Subject: input: touch: maxim: update avdd to 3.3V Nvidia changes to update Maxim touch AVDD voltage setting. Bug 1522154 Bug 200006060 Bug 1522162 Bug 1444604 Bug 1493749 Change-Id: I8a6d349fe9ceead294505597155e9fbb1323e1af Signed-off-by: djung Reviewed-on: http://git-master/r/427871 Reviewed-by: Automatic_Commit_Validation_User GVS: Gerrit_Virtual_Submit Reviewed-by: Harry Hong --- drivers/input/touchscreen/maxim_sti.c | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/drivers/input/touchscreen/maxim_sti.c b/drivers/input/touchscreen/maxim_sti.c index ac0ddf959880..ef89f95e99ea 100644 --- a/drivers/input/touchscreen/maxim_sti.c +++ b/drivers/input/touchscreen/maxim_sti.c @@ -1765,6 +1765,10 @@ static int probe(struct spi_device *spi) goto platform_failure; /* power-up and reset-high */ + pdata->reset(pdata, 0); + ret = regulator_set_voltage(dd->reg_avdd, 3000000, 3000000); + if (ret < 0) + INFO("Touch avdd regulator not set: %d", ret); ret = regulator_control(dd, true); if (ret < 0) goto platform_failure; @@ -1834,6 +1838,26 @@ static int probe(struct spi_device *spi) /* start up Touch Fusion */ dd->start_fusion = true; wake_up_process(dd->thread); + + msleep(2250); + ret = regulator_set_voltage(dd->reg_avdd, 3300000, 3300000); + if (ret < 0) + INFO("Touch avdd regulator not set 3.3V: %d", ret); + usleep_range(15000, 20000); + + /* reset-low and power-down */ + pdata->reset(pdata, 0); + usleep_range(100, 120); + ret = regulator_control(dd, false); + + msleep(750); + + /* power-up and reset-high */ + pdata->reset(pdata, 0); + ret = regulator_control(dd, true); + usleep_range(300, 400); + pdata->reset(pdata, 1); + INFO("driver loaded; version %s; release date %s", DRIVER_VERSION, DRIVER_RELEASE); -- cgit v1.2.3