patch "iio: adc: modify NPCM ADC read reference voltage" added to staging-linus
Subsystems (3)
This is a note to let you know that I've just added the patch titled
iio: adc: modify NPCM ADC read reference voltage
to my staging git tree which can be found at
git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging.git
in the staging-linus branch.
The patch will show up in the next release of the linux-next tree (usually sometime within the next 24 hours during the week.)
The patch will hopefully also be merged in Linus's tree for the next -rc kernel release.
If you have any questions about this process, please let me know.
From 4e63ed6b90803eeb400c392e9ff493200d926b06 Mon Sep 17 00:00:00 2001
From: Tomer Maimon <[email protected]>
Date: Sun, 7 Apr 2019 11:19:28 +0300
Subject: iio: adc: modify NPCM ADC read reference voltage
Checking if regulator is valid before reading
NPCM ADC regulator voltage to avoid system crash
in a case the regulator is not valid.
--- drivers/iio/adc/npcm_adc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/iio/adc/npcm_adc.c +1 -1
@@ -149,7 +149,7 @@ static int npcm_adc_read_raw(struct iio_dev *indio_dev, }return IIO_VAL_INT ;case IIO_CHAN_INFO_SCALE : -if (info->vref) { +if (!IS_ERR (info->vref)) { vref_uv =regulator_get_voltage (info->vref); *val = vref_uv /1000 ; }else {
Signature · 1 line
2.21.0