summaryrefslogtreecommitdiff
path: root/drivers/iio/adc/max1027.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/iio/adc/max1027.c')
-rw-r--r--drivers/iio/adc/max1027.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/iio/adc/max1027.c b/drivers/iio/adc/max1027.c
index 655ab02d03d8..4a42d140a4b0 100644
--- a/drivers/iio/adc/max1027.c
+++ b/drivers/iio/adc/max1027.c
@@ -103,7 +103,7 @@ MODULE_DEVICE_TABLE(of, max1027_adc_dt_ids);
.sign = 'u', \
.realbits = depth, \
.storagebits = 16, \
- .shift = 2, \
+ .shift = (depth == 10) ? 2 : 0, \
.endianness = IIO_BE, \
}, \
}