]> git.baikalelectronics.ru Git - uboot.git/commit
power: regulator: Return success on attempt to disable an always-on regulator
authorLokesh Vutla <lokeshvutla@ti.com>
Mon, 24 Dec 2018 11:07:41 +0000 (16:37 +0530)
committerTom Rini <trini@konsulko.com>
Thu, 27 Dec 2018 12:48:31 +0000 (07:48 -0500)
commit251b77b50aa390668599153fa300962fb61482c6
tree15364a84e350a1a71ead52ead1b313a6dad2a3a5
parent362f331679e076abc58a9f2769ddbb02849069eb
power: regulator: Return success on attempt to disable an always-on regulator

commit 21224298c3d12 ("power: regulator: denied disable on always-on
regulator") throws an error when requested to disable an always-on
regulator. It is right that an always-on regulator should not be
attempted to be disabled. But at the same time regulator framework
should not return an error when such request is received. Instead
it should just return success without attempting to disable the
specified regulator. This is because the requesting driver will
not have the idea if the regulator is always-on or not. The
requesting driver will always try to enable/disable regulator as
per the required flow. So it is upto regulator framework to not
break such scenarios.

Fixes: 21224298c3d12 ("power: regulator: denied disable on always-on regulator")
Reported-by: Jean-Jacques Hiblot <jjhiblot@ti.com>
Reviewed-by: Faiz Abbas <faiz_abbas@ti.com>
Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
drivers/power/regulator/regulator-uclass.c