aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/iio/adc
diff options
context:
space:
mode:
authorSebastian Andrzej Siewior <bigeasy@linutronix.de>2013-12-19 10:28:30 -0500
committerLee Jones <lee.jones@linaro.org>2014-01-07 03:42:38 -0500
commit3954b7bfc665fed878cabe57342bae34d2391478 (patch)
treef5b7dc9cdcac9bf3268e87e619f6e3a1dac019a1 /drivers/iio/adc
parent7e170c6e4f7501bea900aa66b2b27a6ce5001e25 (diff)
mfd: ti_am335x: Drop am335x_tsc_se_update() from resume path
The update of the SE register in MFD doesn't look right as it has nothing to do with it. The better place to do it is in TSC driver (which is already doing it) and in the ADC driver which needs this only in the continues mode. Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de> Acked-by: Jonathan Cameron <jic23@kernel.org> Signed-off-by: Lee Jones <lee.jones@linaro.org>
Diffstat (limited to 'drivers/iio/adc')
-rw-r--r--drivers/iio/adc/ti_am335x_adc.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/iio/adc/ti_am335x_adc.c b/drivers/iio/adc/ti_am335x_adc.c
index 95eef8e89979..e0dc2d0e7590 100644
--- a/drivers/iio/adc/ti_am335x_adc.c
+++ b/drivers/iio/adc/ti_am335x_adc.c
@@ -199,6 +199,7 @@ static int tiadc_buffer_predisable(struct iio_dev *indio_dev)
199 tiadc_writel(adc_dev, REG_IRQCLR, (IRQENB_FIFO1THRES | 199 tiadc_writel(adc_dev, REG_IRQCLR, (IRQENB_FIFO1THRES |
200 IRQENB_FIFO1OVRRUN | IRQENB_FIFO1UNDRFLW)); 200 IRQENB_FIFO1OVRRUN | IRQENB_FIFO1UNDRFLW));
201 am335x_tsc_se_clr(adc_dev->mfd_tscadc, adc_dev->buffer_en_ch_steps); 201 am335x_tsc_se_clr(adc_dev->mfd_tscadc, adc_dev->buffer_en_ch_steps);
202 adc_dev->buffer_en_ch_steps = 0;
202 203
203 /* Flush FIFO of leftover data in the time it takes to disable adc */ 204 /* Flush FIFO of leftover data in the time it takes to disable adc */
204 fifo1count = tiadc_readl(adc_dev, REG_FIFO1CNT); 205 fifo1count = tiadc_readl(adc_dev, REG_FIFO1CNT);
@@ -491,6 +492,7 @@ static int tiadc_resume(struct device *dev)
491 tiadc_writel(adc_dev, REG_CTRL, restore); 492 tiadc_writel(adc_dev, REG_CTRL, restore);
492 493
493 tiadc_step_config(indio_dev); 494 tiadc_step_config(indio_dev);
495 am335x_tsc_se_set(adc_dev->mfd_tscadc, adc_dev->buffer_en_ch_steps);
494 496
495 return 0; 497 return 0;
496} 498}