Message ID | 20170819212410.3084-2-sakari.ailus@linux.intel.com |
---|---|
State | Not Applicable, archived |
Headers | show |
Hi Sakari, Thanks for the update. On 08/19/2017 11:24 PM, Sakari Ailus wrote: > From: Sakari Ailus <sakari.ailus@iki.fi> > > Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com> > --- > .../devicetree/bindings/leds/ams,as3645a.txt | 71 ++++++++++++++++++++++ > 1 file changed, 71 insertions(+) > create mode 100644 Documentation/devicetree/bindings/leds/ams,as3645a.txt > > diff --git a/Documentation/devicetree/bindings/leds/ams,as3645a.txt b/Documentation/devicetree/bindings/leds/ams,as3645a.txt > new file mode 100644 > index 000000000000..12c5ef26ec73 > --- /dev/null > +++ b/Documentation/devicetree/bindings/leds/ams,as3645a.txt > @@ -0,0 +1,71 @@ > +Analog devices AS3645A device tree bindings > + > +The AS3645A flash LED controller can drive two LEDs, one high current > +flash LED and one indicator LED. The high current flash LED can be > +used in torch mode as well. > + > +Ranges below noted as [a, b] are closed ranges between a and b, i.e. a > +and b are included in the range. > + > +Please also see common.txt in the same directory. > + > + > +Required properties > +=================== > + > +compatible : Must be "ams,as3645a". > +reg : The I2C address of the device. Typically 0x30. > + > + > +Required properties of the "flash" child node > +============================================= > + > +flash-timeout-us: Flash timeout in microseconds. The value must be in > + the range [100000, 850000] and divisible by 50000. > +flash-max-microamp: Maximum flash current in microamperes. Has to be > + in the range between [200000, 500000] and > + divisible by 20000. > +led-max-microamp: Maximum torch (assist) current in microamperes. The > + value must be in the range between [20000, 160000] and > + divisible by 20000. > +ams,input-max-microamp: Maximum flash controller input current. The > + value must be in the range [1250000, 2000000] > + and divisible by 50000. > + > + > +Optional properties of the "flash" child node > +============================================= > + > +label : The label of the flash LED. > + > + > +Required properties of the "indicator" child node > +================================================= > + > +led-max-microamp: Maximum indicator current. The allowed values are > + 2500, 5000, 7500 and 10000. > + > +Optional properties of the "indicator" child node > +================================================= > + > +label : The label of the indicator LED. > + > + > +Example > +======= > + > + as3645a@30 { > + reg = <0x30>; > + compatible = "ams,as3645a"; > + flash { > + flash-timeout-us = <150000>; > + flash-max-microamp = <320000>; > + led-max-microamp = <60000>; > + ams,input-max-microamp = <1750000>; > + label = "as3645a:flash"; > + }; > + indicator { > + led-max-microamp = <10000>; > + label = "as3645a:indicator"; > + }; > + }; > For the patch going through media tree: Acked-by: Jacek Anaszewski <jacek.anaszewski@gmail.com>
On Sun, Aug 20, 2017 at 12:24:08AM +0300, Sakari Ailus wrote: > From: Sakari Ailus <sakari.ailus@iki.fi> Commit msg? > Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com> Shouldn't author and SoB be the same email? > --- > .../devicetree/bindings/leds/ams,as3645a.txt | 71 ++++++++++++++++++++++ > 1 file changed, 71 insertions(+) > create mode 100644 Documentation/devicetree/bindings/leds/ams,as3645a.txt Otherwise, Acked-by: Rob Herring <robh@kernel.org> -- To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Hi Rob, On Tue, Aug 22, 2017 at 07:28:10PM -0500, Rob Herring wrote: > On Sun, Aug 20, 2017 at 12:24:08AM +0300, Sakari Ailus wrote: > > From: Sakari Ailus <sakari.ailus@iki.fi> > > Commit msg? I'll add: Document DT bindings for analog devices as3645a flash LED controller which also supports an indicator LED. > > > Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com> > > Shouldn't author and SoB be the same email? I'll change that. > > > --- > > .../devicetree/bindings/leds/ams,as3645a.txt | 71 ++++++++++++++++++++++ > > 1 file changed, 71 insertions(+) > > create mode 100644 Documentation/devicetree/bindings/leds/ams,as3645a.txt > > Otherwise, > > Acked-by: Rob Herring <robh@kernel.org> Thanks!
Hi! > + > +Ranges below noted as [a, b] are closed ranges between a and b, i.e. a > +and b are included in the range. Normally I've seen <a, b> for closed ranges, (a, b) for open ranges. Is that different in your country? Otherwise Acked-by: Pavel Machek <pavel@ucw.cz>
Hi Pavel, Thanks for the review! On 08/28/17 13:33, Pavel Machek wrote: > Hi! > >> + >> +Ranges below noted as [a, b] are closed ranges between a and b, i.e. a >> +and b are included in the range. > > Normally I've seen <a, b> for closed ranges, (a, b) for open > ranges. Is that different in your country? I guess there are different notations. :-) I've seen regular parentheses being used for open ranges, too, but not < and >. Open range is documented in a related well written Wikipedia article: <URL:https://en.wikipedia.org/wiki/Open_range> Are there such open ranges in Czechia? For instance, reindeer generally roam freely in Finnish Lappland. What comes to the patch, I guess "interval" could be a more appropriate term to use in this case: <URL:https://en.wikipedia.org/wiki/Interval_(mathematics)> The patch is in line with the Wikipedia article in notation but not in terminology. I'll send a fix.
Hi! > Thanks for the review! > > On 08/28/17 13:33, Pavel Machek wrote: > > Hi! > > > >> + > >> +Ranges below noted as [a, b] are closed ranges between a and b, i.e. a > >> +and b are included in the range. > > > > Normally I've seen <a, b> for closed ranges, (a, b) for open > > ranges. Is that different in your country? > > I guess there are different notations. :-) I've seen regular parentheses > being used for open ranges, too, but not < and >. > > Open range is documented in a related well written Wikipedia article: > > <URL:https://en.wikipedia.org/wiki/Open_range> > > Are there such open ranges in Czechia? For instance, reindeer generally > roam freely in Finnish Lappland. :-). Well, we have pigs and roes roaming freely in the woods, but would not normally call it open range. > What comes to the patch, I guess "interval" could be a more appropriate > term to use in this case: > > <URL:https://en.wikipedia.org/wiki/Interval_(mathematics)> > > The patch is in line with the Wikipedia article in notation but not in > terminology. I'll send a fix. Ok, that was really nitpicking, thanks! Pavel
diff --git a/Documentation/devicetree/bindings/leds/ams,as3645a.txt b/Documentation/devicetree/bindings/leds/ams,as3645a.txt new file mode 100644 index 000000000000..12c5ef26ec73 --- /dev/null +++ b/Documentation/devicetree/bindings/leds/ams,as3645a.txt @@ -0,0 +1,71 @@ +Analog devices AS3645A device tree bindings + +The AS3645A flash LED controller can drive two LEDs, one high current +flash LED and one indicator LED. The high current flash LED can be +used in torch mode as well. + +Ranges below noted as [a, b] are closed ranges between a and b, i.e. a +and b are included in the range. + +Please also see common.txt in the same directory. + + +Required properties +=================== + +compatible : Must be "ams,as3645a". +reg : The I2C address of the device. Typically 0x30. + + +Required properties of the "flash" child node +============================================= + +flash-timeout-us: Flash timeout in microseconds. The value must be in + the range [100000, 850000] and divisible by 50000. +flash-max-microamp: Maximum flash current in microamperes. Has to be + in the range between [200000, 500000] and + divisible by 20000. +led-max-microamp: Maximum torch (assist) current in microamperes. The + value must be in the range between [20000, 160000] and + divisible by 20000. +ams,input-max-microamp: Maximum flash controller input current. The + value must be in the range [1250000, 2000000] + and divisible by 50000. + + +Optional properties of the "flash" child node +============================================= + +label : The label of the flash LED. + + +Required properties of the "indicator" child node +================================================= + +led-max-microamp: Maximum indicator current. The allowed values are + 2500, 5000, 7500 and 10000. + +Optional properties of the "indicator" child node +================================================= + +label : The label of the indicator LED. + + +Example +======= + + as3645a@30 { + reg = <0x30>; + compatible = "ams,as3645a"; + flash { + flash-timeout-us = <150000>; + flash-max-microamp = <320000>; + led-max-microamp = <60000>; + ams,input-max-microamp = <1750000>; + label = "as3645a:flash"; + }; + indicator { + led-max-microamp = <10000>; + label = "as3645a:indicator"; + }; + };