mfd: ti_am335x_tscadc: Fix TSC operation after ADC continouous mode
authorVignesh R <vigneshr@ti.com>
Mon, 1 Sep 2014 06:31:06 +0000 (12:01 +0530)
committerLee Jones <lee.jones@linaro.org>
Fri, 26 Sep 2014 07:15:50 +0000 (08:15 +0100)
commit6ac734d2242949f41eb1346ca0fd4ed010c937aa
tree36f4d04a4bd6479a2310d8cc87d17888353993ec
parenta654f81640caa0bb648b0e45b792ba846c9bb02d
mfd: ti_am335x_tscadc: Fix TSC operation after ADC continouous mode

After enabling and disabling ADC continuous mode via sysfs, ts_print_raw
fails to return any data. This is because when ADC is configured for
continuous mode, it disables touch screen steps.These steps are not
re-enabled when ADC continuous mode is disabled. Therefore existing values
of REG_SE needs to be cached before enabling continuous mode and
disabling touch screen steps and enabling ADC steps. The cached value
are to be restored to REG_SE once ADC is disabled.

Fixes: 7ca6740cd1cd ("mfd: input: iio: ti_amm335x: Rework TSC/ADC synchronization")
Cc: stable@vger.kernel.org # v3.13+
Signed-off-by: Vignesh R <vigneshr@ti.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
drivers/mfd/ti_am335x_tscadc.c