]> git.baikalelectronics.ru Git - kernel.git/commit
iio: adc: vf610_adc: Fix VALT selection value for REFSEL bits
authorStefan-Gabriel Mirea <stefan-gabriel.mirea@nxp.com>
Thu, 6 Jul 2017 09:06:41 +0000 (10:06 +0100)
committerJonathan Cameron <Jonathan.Cameron@huawei.com>
Thu, 6 Jul 2017 18:39:28 +0000 (19:39 +0100)
commit9e7a573604378ec238830d8054b6c4c2202217b9
tree9a012be79bd30126f336fb2b307d5328622569e8
parentfe364c66291e2bb3fb2549fdc636a6b1de63cdc6
iio: adc: vf610_adc: Fix VALT selection value for REFSEL bits

In order to select the alternate voltage reference pair (VALTH/VALTL), the
right value for the REFSEL field in the ADCx_CFG register is "01", leading
to 0x800 as register mask. See section 8.2.6.4 in the reference manual[1].

[1] http://www.nxp.com/docs/en/reference-manual/VFXXXRM.pdf

Fixes: 64fa14feca2d ("iio:adc:imx: add Freescale Vybrid vf610 adc driver")
Signed-off-by: Stefan-Gabriel Mirea <stefan-gabriel.mirea@nxp.com>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
drivers/iio/adc/vf610_adc.c