iio: adc: sc27xx: fix read big scale voltage not right
authorCixi Geng <cixi.geng1@unisoc.com>
Tue, 19 Apr 2022 14:24:53 +0000 (22:24 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 14 Jun 2022 16:36:05 +0000 (18:36 +0200)
commit31f3f2a598f6eb1917efc3b538af5b4813447188
tree11c57f97427bd20e460ec0196d63095d2c382c9f
parent7c7bc8b82fffb361e1ccb48517c44bf6e259e4b5
iio: adc: sc27xx: fix read big scale voltage not right

[ Upstream commit ad930a75613282400179361e220e58b87386b8c7 ]

Fix wrong configuration value of SC27XX_ADC_SCALE_MASK and
SC27XX_ADC_SCALE_SHIFT by spec documetation.

Fixes: 5df362a6cf49c (iio: adc: Add Spreadtrum SC27XX PMICs ADC support)
Signed-off-by: Cixi Geng <cixi.geng1@unisoc.com>
Reviewed-by: Baolin Wang <baolin.wang7@gmail.com>
Link: https://lore.kernel.org/r/20220419142458.884933-3-gengcixi@gmail.com
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/iio/adc/sc27xx_adc.c