lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <2a2baeb6-d1ae-b564-d20b-039832156121@linaro.org>
Date:   Wed, 2 Nov 2022 13:45:50 -0400
From:   Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>
To:     Sebastian Reichel <sebastian.reichel@...labora.com>,
        Rob Herring <robh@...nel.org>
Cc:     Krzysztof Kozlowski <krzysztof.kozlowski+dt@...aro.org>,
        Orson Zhai <orsonzhai@...il.com>,
        Baolin Wang <baolin.wang@...ux.alibaba.com>,
        Chunyan Zhang <zhang.lyra@...il.com>,
        Pali Rohár <pali@...nel.org>,
        "Andrew F. Davis" <afd@...com>,
        Artur Rojek <contact@...ur-rojek.eu>,
        Matti Vaittinen <matti.vaittinen@...rohmeurope.com>,
        Markus Laine <markus.laine@...rohmeurope.com>,
        Mikko Mutanen <mikko.mutanen@...rohmeurope.com>,
        linux-pm@...r.kernel.org, devicetree@...r.kernel.org,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH] dt-bindings: power: supply: expect specific type for
 monitored-battery

On 31/10/2022 18:56, Sebastian Reichel wrote:
> Hi,
> 
> On Mon, Oct 31, 2022 at 02:26:17PM -0500, Rob Herring wrote:
>> On Fri, Oct 28, 2022 at 07:12:55PM -0400, Krzysztof Kozlowski wrote:
>>> Core schema does not define type of monitored-battery, so the schemas
>>> are expected to reference proper type.
>>>
>>> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>
>>> ---
>>>  Documentation/devicetree/bindings/power/supply/bq27xxx.yaml    | 2 +-
>>>  .../devicetree/bindings/power/supply/ingenic,battery.yaml      | 1 +
>>>  .../devicetree/bindings/power/supply/rohm,bd99954.yaml         | 1 +
>>>  .../devicetree/bindings/power/supply/sc2731-charger.yaml       | 2 +-
>>>  Documentation/devicetree/bindings/power/supply/sc27xx-fg.yaml  | 3 ++-
>>>  5 files changed, 6 insertions(+), 3 deletions(-)
>>>
>>> diff --git a/Documentation/devicetree/bindings/power/supply/bq27xxx.yaml b/Documentation/devicetree/bindings/power/supply/bq27xxx.yaml
>>> index 65fc6049efc1..b04c86ed0f58 100644
>>> --- a/Documentation/devicetree/bindings/power/supply/bq27xxx.yaml
>>> +++ b/Documentation/devicetree/bindings/power/supply/bq27xxx.yaml
>>> @@ -59,6 +59,7 @@ properties:
>>>      description: integer, I2C address of the fuel gauge.
>>>  
>>>    monitored-battery:
>>> +    $ref: /schemas/types.yaml#/definitions/phandle
>>>      description: |
>>>         phandle of battery characteristics node.
>>>         The fuel gauge uses the following battery properties:
>>> @@ -66,7 +67,6 @@ properties:
>>>         - charge-full-design-microamp-hours
>>>         - voltage-min-design-microvolt
>>>         Both or neither of the *-full-design-*-hours properties must be set.
>>> -       See Documentation/devicetree/bindings/power/supply/battery.yaml
>>>  
>>>    power-supplies: true
>>>  
>>> diff --git a/Documentation/devicetree/bindings/power/supply/ingenic,battery.yaml b/Documentation/devicetree/bindings/power/supply/ingenic,battery.yaml
>>> index 46527038bf22..8bdacc30e9d8 100644
>>> --- a/Documentation/devicetree/bindings/power/supply/ingenic,battery.yaml
>>> +++ b/Documentation/devicetree/bindings/power/supply/ingenic,battery.yaml
>>> @@ -27,6 +27,7 @@ properties:
>>>      const: battery
>>>  
>>>    monitored-battery:
>>> +    $ref: /schemas/types.yaml#/definitions/phandle
>>
>> We should not have a type definition multiple times for the same 
>> property. We need to add a common schema defining the type instead.
> 
> I suppose monitored-battery should become part of
> Documentation/devicetree/bindings/power/supply/power-supply.yaml

I'll send a v2.

Best regards,
Krzysztof

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ