Skip to content
Commit 82c89365 authored by Luca Weiss's avatar Luca Weiss Committed by Jonathan Cameron
Browse files

proximity: vl53l0x: Make VDD regulator actually optional



Contrary to what the naming might suggest, devm_regulator_get_optional
returns -ENODEV in case the regulator is not found which will trigger
probe error in this driver.

Use devm_regulator_get instead which will return a dummy regulator that
we can just use as if it was a proper regulator.

Fixes: d3d6dba5 ("proximity: vl53l0x: Handle the VDD regulator")
Signed-off-by: default avatarLuca Weiss <luca.weiss@fairphone.com>
Link: https://lore.kernel.org/r/20220614112049.302278-1-luca.weiss@fairphone.com


Signed-off-by: default avatarJonathan Cameron <Jonathan.Cameron@huawei.com>
parent 0b685f43
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment