]> git.baikalelectronics.ru Git - kernel.git/commit
iio: adc: mxs-lradc: Fix return value check in mxs_lradc_adc_probe()
authorWei Yongjun <weiyongjun1@huawei.com>
Tue, 16 May 2017 15:26:12 +0000 (15:26 +0000)
committerJonathan Cameron <jic23@kernel.org>
Sat, 3 Jun 2017 09:52:31 +0000 (10:52 +0100)
commit06400ddc54427cd38722b3dbf41aa150f778d93c
treed43e49ed59da745c4b01a61597c5a4584d1a287d
parent6c642f89fead60ab3a1ae9c60f9629720e5d94db
iio: adc: mxs-lradc: Fix return value check in mxs_lradc_adc_probe()

In case of error, the function devm_ioremap() returns NULL pointer
not ERR_PTR(). The IS_ERR() test in the return value check should
be replaced with NULL test. Also add NULL test for iores.

Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
drivers/iio/adc/mxs-lradc-adc.c