Re: [PATCH v2] iio: vadc: Fix potential dereference of NULL pointer

Kalle Valo
2022-05-19T15:31:37Z

Yongzhi Liu <lyz_cs@pku.edu.cn> writes:

> The return value of vadc_get_channel() needs to be checked
> to avoid use of NULL pointer. Fix this by adding the null
> pointer check on prop.
>
> Fixes: 0917de94c ("iio: vadc: Qualcomm SPMI PMIC voltage ADC driver")
>
> Signed-off-by: Yongzhi Liu <lyz_cs@pku.edu.cn>
> ---
> drivers/iio/adc/qcom-spmi-vadc.c | 23 ++++++++++++++++++++++-
> 1 file changed, 22 insertions(+), 1 deletion(-)

Did you sent this to linux-wireless by mistake?

--