aboutsummaryrefslogtreecommitdiff
path: root/drivers/iio
diff options
context:
space:
mode:
authorThomas Betker <thomas.betker@rohde-schwarz.com>2015-04-15 21:11:49 +0200
committerSasha Levin <sasha.levin@oracle.com>2015-06-09 14:31:41 -0400
commit3ec936bcf36f91348c08366ebd15d3241298d64f (patch)
tree0f3dcec07dfb2725873a0b4e177075753798ad32 /drivers/iio
parentec4fc281dab476d0e87cb8f82b966ef95d2f1a9a (diff)
iio: adc: xilinx: Fix VREFP scale
[ Upstream commit 00db4e52f4541965f7fda225eb458a75f892017b ] The scaling factor for VREFP is 3.0/4096, not 1.0/4096; fix this to get correct readings. Signed-off-by: Thomas Betker <thomas.betker@rohde-schwarz.com> Cc: <stable@vger.kernel.org> Signed-off-by: Jonathan Cameron <jic23@kernel.org> Signed-off-by: Sasha Levin <sasha.levin@oracle.com>
Diffstat (limited to 'drivers/iio')
-rw-r--r--drivers/iio/adc/xilinx-xadc-core.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/iio/adc/xilinx-xadc-core.c b/drivers/iio/adc/xilinx-xadc-core.c
index 0ad7b502c593..6fa629b3c168 100644
--- a/drivers/iio/adc/xilinx-xadc-core.c
+++ b/drivers/iio/adc/xilinx-xadc-core.c
@@ -856,6 +856,7 @@ static int xadc_read_raw(struct iio_dev *indio_dev,
switch (chan->address) {
case XADC_REG_VCCINT:
case XADC_REG_VCCAUX:
+ case XADC_REG_VREFP:
case XADC_REG_VCCBRAM:
case XADC_REG_VCCPINT:
case XADC_REG_VCCPAUX: