Commit 1887e724 authored by Subbaraya Sundeep Bhatta's avatar Subbaraya Sundeep Bhatta Committed by Jonathan Cameron

iio: adc: xilinx-xadc: assign auxiliary channels address correctly

This patch fixes incorrect logic for assigning address
to auxiliary channels of xilinx xadc.
Signed-off-by: default avatarSubbaraya Sundeep Bhatta <sbhatta@xilinx.com>
Acked-by: default avatarLars-Peter Clausen <lars@metafoo.de>
Cc: Stable@vger.kernel.org
Signed-off-by: default avatarJonathan Cameron <jic23@kernel.org>
parent 04950811
...@@ -1126,7 +1126,7 @@ static int xadc_parse_dt(struct iio_dev *indio_dev, struct device_node *np, ...@@ -1126,7 +1126,7 @@ static int xadc_parse_dt(struct iio_dev *indio_dev, struct device_node *np,
chan->address = XADC_REG_VPVN; chan->address = XADC_REG_VPVN;
} else { } else {
chan->scan_index = 15 + reg; chan->scan_index = 15 + reg;
chan->scan_index = XADC_REG_VAUX(reg - 1); chan->address = XADC_REG_VAUX(reg - 1);
} }
num_channels++; num_channels++;
chan++; chan++;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment