diff mbox series

[v2,2/9] dt-bindings: battery: Add temperature properties

Message ID 20200607144113.10202-3-digetx@gmail.com (mailing list archive)
State Not Applicable, archived
Headers show
Series Summit SMB3xx driver & device-tree | expand

Commit Message

Dmitry Osipenko June 7, 2020, 2:41 p.m. UTC
Document generic battery temperature properties.

Signed-off-by: Dmitry Osipenko <digetx@gmail.com>
---
 .../devicetree/bindings/power/supply/battery.txt       | 10 ++++++++++
 1 file changed, 10 insertions(+)

Comments

Rob Herring (Arm) July 13, 2020, 11:46 p.m. UTC | #1
On Sun, Jun 07, 2020 at 05:41:06PM +0300, Dmitry Osipenko wrote:
> Document generic battery temperature properties.
> 
> Signed-off-by: Dmitry Osipenko <digetx@gmail.com>
> ---
>  .../devicetree/bindings/power/supply/battery.txt       | 10 ++++++++++
>  1 file changed, 10 insertions(+)

This is close to being converted to schema:

https://lore.kernel.org/linux-pm/20200707212914.31540-1-r-rivera-matos@ti.com/
 
> diff --git a/Documentation/devicetree/bindings/power/supply/battery.txt b/Documentation/devicetree/bindings/power/supply/battery.txt
> index 5e29595edd74..e0c35eff9d3f 100644
> --- a/Documentation/devicetree/bindings/power/supply/battery.txt
> +++ b/Documentation/devicetree/bindings/power/supply/battery.txt
> @@ -45,6 +45,16 @@ Optional Properties:
>     and corresponding battery internal resistance percent, which is used to look
>     up the resistance percent according to current temperature to get a accurate
>     batterty internal resistance in different temperatures.
> + - temperature-ambient-min-alert-celsius: Alert when ambient temperature of a
> +   battery is lower than threshold value.
> + - temperature-ambient-max-alert-celsius: Alert when ambient temperature of a
> +   battery is higher than threshold value.
> + - temperature-min-alert-celsius: Alert when battery temperature is lower
> +   than threshold value.
> + - temperature-max-alert-celsius: Alert when battery temperature is higher
> +   than threshold value.
> + - temperature-min-celsius: minimum temperature at which battery can operate
> + - temperature-max-celsius: maximum temperature at which battery can operate

Perhaps 'temperature' is redundant since we have units.

Perhaps do <min max> properties given specifying only min or max is 
probably not valid?

Rob
Dmitry Osipenko July 16, 2020, 5:24 p.m. UTC | #2
14.07.2020 02:46, Rob Herring пишет:
> On Sun, Jun 07, 2020 at 05:41:06PM +0300, Dmitry Osipenko wrote:
>> Document generic battery temperature properties.
>>
>> Signed-off-by: Dmitry Osipenko <digetx@gmail.com>
>> ---
>>  .../devicetree/bindings/power/supply/battery.txt       | 10 ++++++++++
>>  1 file changed, 10 insertions(+)
> 
> This is close to being converted to schema:
> 
> https://lore.kernel.org/linux-pm/20200707212914.31540-1-r-rivera-matos@ti.com/

Thanks! I'll keep an eye on this patch.

>> diff --git a/Documentation/devicetree/bindings/power/supply/battery.txt b/Documentation/devicetree/bindings/power/supply/battery.txt
>> index 5e29595edd74..e0c35eff9d3f 100644
>> --- a/Documentation/devicetree/bindings/power/supply/battery.txt
>> +++ b/Documentation/devicetree/bindings/power/supply/battery.txt
>> @@ -45,6 +45,16 @@ Optional Properties:
>>     and corresponding battery internal resistance percent, which is used to look
>>     up the resistance percent according to current temperature to get a accurate
>>     batterty internal resistance in different temperatures.
>> + - temperature-ambient-min-alert-celsius: Alert when ambient temperature of a
>> +   battery is lower than threshold value.
>> + - temperature-ambient-max-alert-celsius: Alert when ambient temperature of a
>> +   battery is higher than threshold value.
>> + - temperature-min-alert-celsius: Alert when battery temperature is lower
>> +   than threshold value.
>> + - temperature-max-alert-celsius: Alert when battery temperature is higher
>> +   than threshold value.
>> + - temperature-min-celsius: minimum temperature at which battery can operate
>> + - temperature-max-celsius: maximum temperature at which battery can operate
> 
> Perhaps 'temperature' is redundant since we have units.
> 
> Perhaps do <min max> properties given specifying only min or max is 
> probably not valid?

Thank you for the suggestions, I'll consider them for the v3!
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/power/supply/battery.txt b/Documentation/devicetree/bindings/power/supply/battery.txt
index 5e29595edd74..e0c35eff9d3f 100644
--- a/Documentation/devicetree/bindings/power/supply/battery.txt
+++ b/Documentation/devicetree/bindings/power/supply/battery.txt
@@ -45,6 +45,16 @@  Optional Properties:
    and corresponding battery internal resistance percent, which is used to look
    up the resistance percent according to current temperature to get a accurate
    batterty internal resistance in different temperatures.
+ - temperature-ambient-min-alert-celsius: Alert when ambient temperature of a
+   battery is lower than threshold value.
+ - temperature-ambient-max-alert-celsius: Alert when ambient temperature of a
+   battery is higher than threshold value.
+ - temperature-min-alert-celsius: Alert when battery temperature is lower
+   than threshold value.
+ - temperature-max-alert-celsius: Alert when battery temperature is higher
+   than threshold value.
+ - temperature-min-celsius: minimum temperature at which battery can operate
+ - temperature-max-celsius: maximum temperature at which battery can operate
 
 Battery properties are named, where possible, for the corresponding
 elements in enum power_supply_property, defined in