Commit 257b2335 authored by David Lechner's avatar David Lechner Committed by Mark Brown

regulator: devres: fix devm_regulator_get_enable_read_voltage() return

The devm_regulator_get_enable_read_voltage() function is supposed to
return the voltage that the regulator is currently set to. However, it
currently returns 0.

Fixes: b250c20b ("regulator: devres: add API for reference voltage supplies")
Signed-off-by: default avatarDavid Lechner <dlechner@baylibre.com>
Link: https://lore.kernel.org/r/20240506-regulator-devm_regulator_get_enable_read_voltage-fixes-v1-1-356cdd152067@baylibre.comSigned-off-by: default avatarMark Brown <broonie@kernel.org>
parent 48b6faae
......@@ -193,7 +193,7 @@ int devm_regulator_get_enable_read_voltage(struct device *dev, const char *id)
if (ret < 0)
goto err_release_action;
return 0;
return ret;
err_release_action:
devm_release_action(dev, regulator_action_disable, r);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment