Re: [PATCH 1/1] regulator: Only enable disabled regulators on resume

2015-03-11 Thread Javier Martinez Canillas
On 03/11/2015 11:57 AM, Mark Brown wrote: > On Mon, Mar 09, 2015 at 08:40:20AM +0100, Javier Martinez Canillas wrote: >> On 03/08/2015 08:38 PM, Mark Brown wrote: >> > You mean _do_enable(), not _enable() here. It's not really a leftover > >> No, I meant _enable() here. What I said is that _enabl

Re: [PATCH 1/1] regulator: Only enable disabled regulators on resume

2015-03-11 Thread Mark Brown
On Mon, Mar 09, 2015 at 08:40:20AM +0100, Javier Martinez Canillas wrote: > On 03/08/2015 08:38 PM, Mark Brown wrote: > > On Wed, Mar 04, 2015 at 02:45:00PM +0100, Javier Martinez Canillas wrote: > >> The thing is that _regulator_is_enabled() used to return -EINVAL if > >> the rdev didn't have an

Re: [PATCH 1/1] regulator: Only enable disabled regulators on resume

2015-03-09 Thread Javier Martinez Canillas
On 03/08/2015 08:38 PM, Mark Brown wrote: > On Wed, Mar 04, 2015 at 02:45:00PM +0100, Javier Martinez Canillas wrote: > >> The thing is that _regulator_is_enabled() used to return -EINVAL if >> the rdev didn't have an .is_enabled callback but that changed in >> commit 9a7f6a4c6edc8 ("regulator: As

Re: [PATCH 1/1] regulator: Only enable disabled regulators on resume

2015-03-08 Thread Mark Brown
On Mon, Mar 02, 2015 at 09:40:39PM +0100, Javier Martinez Canillas wrote: > After leaving from system wide suspend state, regulator_suspend_finish() > turn on regulators that may be turned off by regulator_suspend_prepare() > but it tries to enable all regulators that have an enable count > 0 or >

Re: [PATCH 1/1] regulator: Only enable disabled regulators on resume

2015-03-08 Thread Mark Brown
On Wed, Mar 04, 2015 at 02:45:00PM +0100, Javier Martinez Canillas wrote: > The thing is that _regulator_is_enabled() used to return -EINVAL if > the rdev didn't have an .is_enabled callback but that changed in > commit 9a7f6a4c6edc8 ("regulator: Assume regulators are enabled if > they don't repor

Re: [PATCH 1/1] regulator: Only enable disabled regulators on resume

2015-03-04 Thread Javier Martinez Canillas
Hello Doug, On 03/03/2015 08:05 PM, Javier Martinez Canillas wrote: > On 03/03/2015 06:24 PM, Doug Anderson wrote: >>> >>> diff --git a/drivers/regulator/core.c b/drivers/regulator/core.c >>> index f2452148c8da..8551400d57e4 100644 >>> --- a/drivers/regulator/core.c >>> +++ b/drivers/regulator/cor

Re: [PATCH 1/1] regulator: Only enable disabled regulators on resume

2015-03-03 Thread Javier Martinez Canillas
Hello Doug, On 03/03/2015 06:24 PM, Doug Anderson wrote: > Javier, > > On Mon, Mar 2, 2015 at 12:40 PM, Javier Martinez Canillas > wrote: >> After leaving from system wide suspend state, regulator_suspend_finish() >> turn on regulators that may be turned off by regulator_suspend_prepare() >> but

Re: [PATCH 1/1] regulator: Only enable disabled regulators on resume

2015-03-03 Thread Doug Anderson
Javier, On Mon, Mar 2, 2015 at 12:40 PM, Javier Martinez Canillas wrote: > After leaving from system wide suspend state, regulator_suspend_finish() > turn on regulators that may be turned off by regulator_suspend_prepare() > but it tries to enable all regulators that have an enable count > 0 or >

[PATCH 1/1] regulator: Only enable disabled regulators on resume

2015-03-02 Thread Javier Martinez Canillas
After leaving from system wide suspend state, regulator_suspend_finish() turn on regulators that may be turned off by regulator_suspend_prepare() but it tries to enable all regulators that have an enable count > 0 or that were marked as "always-on" regardless if those were disabled or not. Trying