Explorar o código

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: Subbaraya Sundeep Bhatta <sbhatta@xilinx.com>
Acked-by: Lars-Peter Clausen <lars@metafoo.de>
Cc: Stable@vger.kernel.org
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
Subbaraya Sundeep Bhatta %!s(int64=11) %!d(string=hai) anos
pai
achega
1887e724e2
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      drivers/iio/adc/xilinx-xadc-core.c

+ 1 - 1
drivers/iio/adc/xilinx-xadc-core.c

@@ -1126,7 +1126,7 @@ static int xadc_parse_dt(struct iio_dev *indio_dev, struct device_node *np,
 				chan->address = XADC_REG_VPVN;
 			} else {
 				chan->scan_index = 15 + reg;
-				chan->scan_index = XADC_REG_VAUX(reg - 1);
+				chan->address = XADC_REG_VAUX(reg - 1);
 			}
 			num_channels++;
 			chan++;