lkml.org 
[lkml]   [2014]   [Oct]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v2 5/7] regulator: max77802: Document regulator opmode DT properties
Hello Mark,

On 10/17/2014 03:54 PM, Mark Brown wrote:
> On Fri, Oct 17, 2014 at 02:39:15PM +0200, Javier Martinez Canillas wrote:
>
>> Just to be sure I understood correctly, are you suggesting something like this?
>
>> ldo1_reg: LDO1 {
>> regulator-name = "vdd_1v0";
>> regulator-min-microvolt = <1000000>;
>> regulator-max-microvolt = <1000000>;
>> regulator-state-mem {
>> regulator-on-in-suspend;
>> regulator-mode = <MAX77802_OPMODE_LP>;
>> };
>> };
>
>> In other words, extending Chanwoo Choi's original suspend state binding to add
>> the regulator-mode property that was present in his v3 [0] but instead trying
>> to use the standard REGULATOR_MODE_*, say that each regulator driver should
>> define it's own device-specific set of modes and a do the translation to fill
>> standard modes in the struct regulation_constraints {initial,disk,mem} mode?
>
>> That way adding new suspend states, will only require changing the generic
>> regulator binding but not the regulator driver specific bindings.
>
> Something like that, yes. Not sure if numbers or strings are the best

Perfect will re-spin then, many thanks again for your feedback and suggestions.

> way of doing the mode but it probably doesn't matter too much now we
> have preprocessor support for inclue files.
>

I usually prefer to avoid strings when possible since a typo can't be
detected when building the DTB and could be hard to debug at runtime while
a typo on a macro will be detected by the preprocessor at build time.

But I don't have a strong opinion either.

Best regards,
Javier


\
 
 \ /
  Last update: 2014-10-17 16:41    [W:0.044 / U:0.980 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site