regulator: rt4831: Fix return value check in rt4831_regulator_probe()
In case of error, the function dev_get_regmap() returns NULL pointer not ERR_PTR(). The IS_ERR() test in the return value check should be replaced with NULL test. Fixes: 9351ab8b ("regulator: rt4831: Adds support for Richtek RT4831 DSV regulator") Reported-by:Hulk Robot <hulkci@huawei.com> Signed-off-by:
Wei Yongjun <weiyongjun1@huawei.com> Link: https://lore.kernel.org/r/20210305034930.3236099-1-weiyongjun1@huawei.comSigned-off-by:
Mark Brown <broonie@kernel.org>
Showing
Please register or sign in to comment