lkml.org 
[lkml]   [2012]   [Aug]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH V2] regulator: disable supply regulator if it is enabled for boot-on
On Thu, Aug 30, 2012 at 08:24:15PM +0200, Rabin Vincent wrote:

> This does not handle the case where a regulator is not set boot_on but
> is considered on (for example, because of the lack of an is_enabled
> callback), and is later actually enabled by a consumer before
> regulator_init_complete(). In this case, the supply's use count will
> still be one more than it should be, because the "&& c->boot_on"
> condition above will fail.

> To fix this, you should probably note which regulators' supplies you
> enable in regulator_register() and use that information in the above two
> checks here in regulator_init_complete().

Yeah, I didn't read this properly yet but this was my main concern -
this should all just fall out naturally through the normal disable
process. Doing special case bodges feels really fragile and error
prone.


\
 
 \ /
  Last update: 2012-08-30 22:41    [W:0.075 / U:3.100 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site