summaryrefslogtreecommitdiffstats
path: root/drivers/iio/adc
diff options
context:
space:
mode:
authorOlivier Moysan <olivier.moysan@st.com>2019-11-27 14:07:29 +0100
committerJonathan Cameron <Jonathan.Cameron@huawei.com>2020-01-13 21:56:01 +0000
commitdc26935fb60e8da8d59655dd2ec0de47b20d7d8f (patch)
treef214a172d3f09d60f9be5bfcd80d305731c10c78 /drivers/iio/adc
parentecb27c5e430785018199dd42e566711022d32523 (diff)
downloadlinux-dc26935fb60e8da8d59655dd2ec0de47b20d7d8f.tar.bz2
iio: adc: stm32-dfsdm: fix single conversion
Apply data formatting to single conversion, as this is already done in continuous and trigger modes. Fixes: 102afde62937 ("iio: adc: stm32-dfsdm: manage data resolution in trigger mode") Signed-off-by: Olivier Moysan <olivier.moysan@st.com> Cc: <Stable@vger.kernel.org> Acked-by: Fabrice Gasnier <fabrice.gasnier@st.com> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Diffstat (limited to 'drivers/iio/adc')
-rw-r--r--drivers/iio/adc/stm32-dfsdm-adc.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/iio/adc/stm32-dfsdm-adc.c b/drivers/iio/adc/stm32-dfsdm-adc.c
index 74a2211bdff4..1c9b05d11dc5 100644
--- a/drivers/iio/adc/stm32-dfsdm-adc.c
+++ b/drivers/iio/adc/stm32-dfsdm-adc.c
@@ -1204,6 +1204,8 @@ static int stm32_dfsdm_single_conv(struct iio_dev *indio_dev,
stm32_dfsdm_stop_conv(adc);
+ stm32_dfsdm_process_data(adc, res);
+
stop_dfsdm:
stm32_dfsdm_stop_dfsdm(adc->dfsdm);