From 10d3af905f9d3b0a93c70adc83c3dcf66690e6bb Mon Sep 17 00:00:00 2001 From: Michael Hennerich Date: Mon, 3 Jun 2013 09:04:00 +0100 Subject: iio:inkern: Fix typo/bug in convert raw to processed. commit 6c5d4c96f979611f0165dc825af9e1cea8dd35b9 upstream. Signed-off-by: Michael Hennerich Signed-off-by: Jonathan Cameron Signed-off-by: Jonghwan Choi Signed-off-by: Greg Kroah-Hartman --- drivers/iio/inkern.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/iio/inkern.c b/drivers/iio/inkern.c index b289915b846..8ff1a2de1d9 100644 --- a/drivers/iio/inkern.c +++ b/drivers/iio/inkern.c @@ -279,7 +279,7 @@ static int iio_convert_raw_to_processed_unlocked(struct iio_channel *chan, s64 raw64 = raw; int ret; - ret = iio_channel_read(chan, &offset, NULL, IIO_CHAN_INFO_SCALE); + ret = iio_channel_read(chan, &offset, NULL, IIO_CHAN_INFO_OFFSET); if (ret == 0) raw64 += offset; -- cgit v1.2.3-18-g5258