summaryrefslogtreecommitdiff
path: root/drivers/iio/dac/ad5592r-base.c
diff options
context:
space:
mode:
authorIngo Molnar <mingo@kernel.org>2016-07-08 18:27:47 +0300
committerIngo Molnar <mingo@kernel.org>2016-07-08 18:27:47 +0300
commit9e7f7f5425e6d1492109a537ee88c99b29580655 (patch)
tree81f9d68abb5b793aadaf80bd6940af04e3c16eb9 /drivers/iio/dac/ad5592r-base.c
parent6daa2ec0b3e3808c55329d12de3c157cf38b17b0 (diff)
parentf80fd3a5fff88a9ace7e8cd11d07cf874a63ea9f (diff)
downloadlinux-9e7f7f5425e6d1492109a537ee88c99b29580655.tar.xz
Merge branch 'x86/mm' into x86/boot, to pick up dependencies
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'drivers/iio/dac/ad5592r-base.c')
-rw-r--r--drivers/iio/dac/ad5592r-base.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/iio/dac/ad5592r-base.c b/drivers/iio/dac/ad5592r-base.c
index 948f600e7059..69bde5909854 100644
--- a/drivers/iio/dac/ad5592r-base.c
+++ b/drivers/iio/dac/ad5592r-base.c
@@ -525,7 +525,7 @@ static int ad5592r_alloc_channels(struct ad5592r_state *st)
device_for_each_child_node(st->dev, child) {
ret = fwnode_property_read_u32(child, "reg", &reg);
- if (ret || reg > ARRAY_SIZE(st->channel_modes))
+ if (ret || reg >= ARRAY_SIZE(st->channel_modes))
continue;
ret = fwnode_property_read_u32(child, "adi,mode", &tmp);