mirror of
https://github.com/Fishwaldo/u-boot.git
synced 2025-03-18 21:21:37 +00:00
Revert "power: regulator: Return success on attempt to disable an always-on regulator"
This reverts commit e17e0ceb83
.
It is advised to return an error when trying to disable an always-on
regulator and let the consumer driver handle the error if needed.
Reviewed-by: Simon Glass <sjg@chromium.org>
Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
This commit is contained in:
parent
91b3a1866b
commit
f93fab3126
1 changed files with 1 additions and 1 deletions
|
@ -113,7 +113,7 @@ int regulator_set_enable(struct udevice *dev, bool enable)
|
||||||
|
|
||||||
uc_pdata = dev_get_uclass_platdata(dev);
|
uc_pdata = dev_get_uclass_platdata(dev);
|
||||||
if (!enable && uc_pdata->always_on)
|
if (!enable && uc_pdata->always_on)
|
||||||
return 0;
|
return -EACCES;
|
||||||
|
|
||||||
return ops->set_enable(dev, enable);
|
return ops->set_enable(dev, enable);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue