Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f1530414 authored by Lars-Peter Clausen's avatar Lars-Peter Clausen Committed by Jonathan Cameron
Browse files

staging:iio:adis16260: Fix reading calibscale



Return the actual value read from the device and not just the mask.

Signed-off-by: default avatarLars-Peter Clausen <lars@metafoo.de>
Signed-off-by: default avatarJonathan Cameron <jic23@kernel.org>
parent d9a0134e
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -223,7 +223,7 @@ static int adis16260_read_raw(struct iio_dev *indio_dev,
			mutex_unlock(&indio_dev->mlock);
			return ret;
		}
		*val = (1 << bits) - 1;
		*val = val16;
		mutex_unlock(&indio_dev->mlock);
		return IIO_VAL_INT;
	}