[2/3] dt-bindings: power: supply: pm8941-coincell: Don't require charging properties

Message ID 20230213204950.2100538-2-konrad.dybcio@linaro.org
State New
Headers
Series [1/3] dt-bindings: power: supply: pm8941-coincell: Add PM8998 compatible |

Commit Message

Konrad Dybcio Feb. 13, 2023, 8:49 p.m. UTC
  It's fine for these properties to be absent, as the driver doesn't fail
without them and functions with settings inherited from the reset/previous
stage bootloader state.

Fixes: 6c463222a21d ("dt-bindings: power: supply: pm8941-coincell: Convert to DT schema format")
Signed-off-by: Konrad Dybcio <konrad.dybcio@linaro.org>
---
 .../devicetree/bindings/power/supply/qcom,pm8941-coincell.yaml  | 2 --
 1 file changed, 2 deletions(-)
  

Comments

Sebastian Reichel Feb. 13, 2023, 9:27 p.m. UTC | #1
Hi,

On Mon, Feb 13, 2023 at 09:49:49PM +0100, Konrad Dybcio wrote:
> It's fine for these properties to be absent, as the driver doesn't fail
> without them and functions with settings inherited from the reset/previous
> stage bootloader state.
> 
> Fixes: 6c463222a21d ("dt-bindings: power: supply: pm8941-coincell: Convert to DT schema format")
> Signed-off-by: Konrad Dybcio <konrad.dybcio@linaro.org>
> ---

Please update the description of these properties to describe the
default behaviour.

-- Sebastian

>  .../devicetree/bindings/power/supply/qcom,pm8941-coincell.yaml  | 2 --
>  1 file changed, 2 deletions(-)
> 
> diff --git a/Documentation/devicetree/bindings/power/supply/qcom,pm8941-coincell.yaml b/Documentation/devicetree/bindings/power/supply/qcom,pm8941-coincell.yaml
> index b7b58aed3f3c..d62e3af55560 100644
> --- a/Documentation/devicetree/bindings/power/supply/qcom,pm8941-coincell.yaml
> +++ b/Documentation/devicetree/bindings/power/supply/qcom,pm8941-coincell.yaml
> @@ -43,8 +43,6 @@ properties:
>  required:
>    - compatible
>    - reg
> -  - qcom,rset-ohms
> -  - qcom,vset-millivolts
>  
>  additionalProperties: false
>  
> -- 
> 2.39.1
>
  
Konrad Dybcio Feb. 13, 2023, 9:41 p.m. UTC | #2
On 13.02.2023 22:27, Sebastian Reichel wrote:
> Hi,
> 
> On Mon, Feb 13, 2023 at 09:49:49PM +0100, Konrad Dybcio wrote:
>> It's fine for these properties to be absent, as the driver doesn't fail
>> without them and functions with settings inherited from the reset/previous
>> stage bootloader state.
>>
>> Fixes: 6c463222a21d ("dt-bindings: power: supply: pm8941-coincell: Convert to DT schema format")
>> Signed-off-by: Konrad Dybcio <konrad.dybcio@linaro.org>
>> ---
> 
> Please update the description of these properties to describe the
> default behaviour.
Not sure if there's any default behavior other than "go with
whatever was there previously, no matter how it got there".

Is it okay if I just add:

"If unspecified, inherit the bootloader configuration"

?

Konrad
> 
> -- Sebastian
> 
>>  .../devicetree/bindings/power/supply/qcom,pm8941-coincell.yaml  | 2 --
>>  1 file changed, 2 deletions(-)
>>
>> diff --git a/Documentation/devicetree/bindings/power/supply/qcom,pm8941-coincell.yaml b/Documentation/devicetree/bindings/power/supply/qcom,pm8941-coincell.yaml
>> index b7b58aed3f3c..d62e3af55560 100644
>> --- a/Documentation/devicetree/bindings/power/supply/qcom,pm8941-coincell.yaml
>> +++ b/Documentation/devicetree/bindings/power/supply/qcom,pm8941-coincell.yaml
>> @@ -43,8 +43,6 @@ properties:
>>  required:
>>    - compatible
>>    - reg
>> -  - qcom,rset-ohms
>> -  - qcom,vset-millivolts
>>  
>>  additionalProperties: false
>>  
>> -- 
>> 2.39.1
>>
  
Sebastian Reichel Feb. 13, 2023, 10:45 p.m. UTC | #3
Hi,

On Mon, Feb 13, 2023 at 10:41:10PM +0100, Konrad Dybcio wrote:
> On 13.02.2023 22:27, Sebastian Reichel wrote:
> > On Mon, Feb 13, 2023 at 09:49:49PM +0100, Konrad Dybcio wrote:
> >> It's fine for these properties to be absent, as the driver doesn't fail
> >> without them and functions with settings inherited from the reset/previous
> >> stage bootloader state.
> >>
> >> Fixes: 6c463222a21d ("dt-bindings: power: supply: pm8941-coincell: Convert to DT schema format")
> >> Signed-off-by: Konrad Dybcio <konrad.dybcio@linaro.org>
> >> ---
> > Please update the description of these properties to describe the
> > default behaviour.
> Not sure if there's any default behavior other than "go with
> whatever was there previously, no matter how it got there".

I got that from the patch description, but that behaviour should be
described in the binding.

> Is it okay if I just add:
> 
> "If unspecified, inherit the bootloader configuration"

Technically the bindings are also for bootloaders. I suggest:

If unspecified, inherit the previous configuration (e.g. from
bootloader or hardware default value).

-- Sebastian
  

Patch

diff --git a/Documentation/devicetree/bindings/power/supply/qcom,pm8941-coincell.yaml b/Documentation/devicetree/bindings/power/supply/qcom,pm8941-coincell.yaml
index b7b58aed3f3c..d62e3af55560 100644
--- a/Documentation/devicetree/bindings/power/supply/qcom,pm8941-coincell.yaml
+++ b/Documentation/devicetree/bindings/power/supply/qcom,pm8941-coincell.yaml
@@ -43,8 +43,6 @@  properties:
 required:
   - compatible
   - reg
-  - qcom,rset-ohms
-  - qcom,vset-millivolts
 
 additionalProperties: false