aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMihail Chindris <[email protected]>2021-10-07 08:00:34 +0000
committerJonathan Cameron <[email protected]>2021-10-07 16:50:08 +0100
commitd9de0fbdeb0103a204055efb69cb5cc8f5f12a6a (patch)
treeb0fe4e63660f7b03104f0ab99aae9db375118aff
parent03748d4e003c9f2ad3cd00e3e46f054dcad6b96d (diff)
drivers: iio: dac: ad5766: Fix dt property name
In the documentation the name for the property is output-range-microvolts which is a standard name, therefore this name must be used. Fixes: fd9373e41b9ba ("iio: dac: ad5766: add driver support for AD5766") Signed-off-by: Mihail Chindris <[email protected]> Reviewed-by: Alexandru Ardelean <[email protected]> Link: https://lore.kernel.org/r/[email protected] Cc: <[email protected]> Signed-off-by: Jonathan Cameron <[email protected]>
-rw-r--r--drivers/iio/dac/ad5766.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/iio/dac/ad5766.c b/drivers/iio/dac/ad5766.c
index 3104ec32dfac..dafda84fdea3 100644
--- a/drivers/iio/dac/ad5766.c
+++ b/drivers/iio/dac/ad5766.c
@@ -503,13 +503,13 @@ static int ad5766_get_output_range(struct ad5766_state *st)
int i, ret, min, max, tmp[2];
ret = device_property_read_u32_array(&st->spi->dev,
- "output-range-voltage",
+ "output-range-microvolts",
tmp, 2);
if (ret)
return ret;
- min = tmp[0] / 1000;
- max = tmp[1] / 1000;
+ min = tmp[0] / 1000000;
+ max = tmp[1] / 1000000;
for (i = 0; i < ARRAY_SIZE(ad5766_span_tbl); i++) {
if (ad5766_span_tbl[i].min != min ||
ad5766_span_tbl[i].max != max)