drm/panel: lvds: Handle the optional regulator case properly
The devm_regulator_get_optional function, unlike it was assumed in the
commit
a1c55bccf600 ("drm/panel: lvds: Add support for the power-supply
property"), is actually returning an error pointer with -ENODEV instead of
NULL when there's no regulator to find.
Make sure we handle that case properly.
Reviewed-by: Laurent Pinchart <[email protected]>
Tested-by: Laurent Pinchart <[email protected]>
Fixes: a1c55bccf600 ("drm/panel: lvds: Add support for the power-supply property")
Signed-off-by: Maxime Ripard <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]