From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.4 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,USER_AGENT_SANE_1 autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id B42CBC4724C for ; Mon, 4 May 2020 17:17:21 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 914CE2068E for ; Mon, 4 May 2020 17:17:21 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=ti.com header.i=@ti.com header.b="l+g0cdu5" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730701AbgEDRRU (ORCPT ); Mon, 4 May 2020 13:17:20 -0400 Received: from lelv0143.ext.ti.com ([198.47.23.248]:51780 "EHLO lelv0143.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729714AbgEDRRT (ORCPT ); Mon, 4 May 2020 13:17:19 -0400 Received: from fllv0035.itg.ti.com ([10.64.41.0]) by lelv0143.ext.ti.com (8.15.2/8.15.2) with ESMTP id 044HHHJp086798; Mon, 4 May 2020 12:17:17 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1588612637; bh=5HkS3LXYDb7FAZsgCE8f3t5PScofPnie5Sj76ZrQ+os=; h=Subject:To:CC:References:From:Date:In-Reply-To; b=l+g0cdu5ta2o3KZhui48hM+F5oqQrJm4EBMoSrRoN1+phRW9Fa+qz8L3cSi/IKH2V /pqMHGZEZu8QLp+2lbUNCOknFn0oIpveovFuoOnQMVJbMppFuFBdMZcD1N1I6xXEfx FGX1n0DtQ6aj+wHn0I75BwJIOBafyvPvYbunfKgk= Received: from DLEE108.ent.ti.com (dlee108.ent.ti.com [157.170.170.38]) by fllv0035.itg.ti.com (8.15.2/8.15.2) with ESMTP id 044HHH8i005817; Mon, 4 May 2020 12:17:17 -0500 Received: from DLEE106.ent.ti.com (157.170.170.36) by DLEE108.ent.ti.com (157.170.170.38) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1979.3; Mon, 4 May 2020 12:17:17 -0500 Received: from lelv0327.itg.ti.com (10.180.67.183) by DLEE106.ent.ti.com (157.170.170.36) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1979.3 via Frontend Transport; Mon, 4 May 2020 12:17:17 -0500 Received: from [10.250.65.13] (ileax41-snat.itg.ti.com [10.172.224.153]) by lelv0327.itg.ti.com (8.15.2/8.15.2) with ESMTP id 044HHHLP050906; Mon, 4 May 2020 12:17:17 -0500 Subject: Re: [PATCH] dt-bindings: power: Convert bq27xxx dt to yaml To: "Andrew F. Davis" , CC: , , , , =?UTF-8?Q?Pali_Roh=c3=a1r?= References: <20200504164156.21469-1-dmurphy@ti.com> <1ddf643b-c54e-0a60-ee14-8ea137f2bfc9@ti.com> <5a7220c7-6c0b-6997-f773-e4b1133d628b@ti.com> From: Dan Murphy Message-ID: <1bd44e87-dc61-f38d-63ad-9a783b36569c@ti.com> Date: Mon, 4 May 2020 12:08:34 -0500 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.7.0 MIME-Version: 1.0 In-Reply-To: <5a7220c7-6c0b-6997-f773-e4b1133d628b@ti.com> Content-Type: text/plain; charset="utf-8"; format=flowed Content-Transfer-Encoding: 8bit Content-Language: en-US X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Andrew On 5/4/20 12:08 PM, Andrew F. Davis wrote: > On 5/4/20 12:44 PM, Dan Murphy wrote: >> Adding Andrew in manually. >> >> On 5/4/20 11:41 AM, Dan Murphy wrote: >>> Convert the bq27xxx.txt to yaml format >>> >>> CC: Pali Rohár >>> CC: Andrew F. Davis" >>> Signed-off-by: Dan Murphy >>> --- >>>   .../bindings/power/supply/bq27xxx.txt         | 56 ----------- >>>   .../bindings/power/supply/bq27xxx.yaml        | 95 +++++++++++++++++++ >>>   2 files changed, 95 insertions(+), 56 deletions(-) >>>   delete mode 100644 >>> Documentation/devicetree/bindings/power/supply/bq27xxx.txt >>>   create mode 100644 >>> Documentation/devicetree/bindings/power/supply/bq27xxx.yaml >>> >>> diff --git >>> a/Documentation/devicetree/bindings/power/supply/bq27xxx.txt >>> b/Documentation/devicetree/bindings/power/supply/bq27xxx.txt >>> deleted file mode 100644 >>> index 4fa8e08df2b6..000000000000 >>> --- a/Documentation/devicetree/bindings/power/supply/bq27xxx.txt >>> +++ /dev/null >>> @@ -1,56 +0,0 @@ >>> -TI BQ27XXX fuel gauge family >>> - >>> -Required properties: >>> -- compatible: contains one of the following: >>> - * "ti,bq27200" - BQ27200 >>> - * "ti,bq27210" - BQ27210 >>> - * "ti,bq27500" - deprecated, use revision specific property below >>> - * "ti,bq27510" - deprecated, use revision specific property below >>> - * "ti,bq27520" - deprecated, use revision specific property below >>> - * "ti,bq27500-1" - BQ27500/1 >>> - * "ti,bq27510g1" - BQ27510-g1 >>> - * "ti,bq27510g2" - BQ27510-g2 >>> - * "ti,bq27510g3" - BQ27510-g3 >>> - * "ti,bq27520g1" - BQ27520-g1 >>> - * "ti,bq27520g2" - BQ27520-g2 >>> - * "ti,bq27520g3" - BQ27520-g3 >>> - * "ti,bq27520g4" - BQ27520-g4 >>> - * "ti,bq27521" - BQ27521 >>> - * "ti,bq27530" - BQ27530 >>> - * "ti,bq27531" - BQ27531 >>> - * "ti,bq27541" - BQ27541 >>> - * "ti,bq27542" - BQ27542 >>> - * "ti,bq27546" - BQ27546 >>> - * "ti,bq27742" - BQ27742 >>> - * "ti,bq27545" - BQ27545 >>> - * "ti,bq27411" - BQ27411 >>> - * "ti,bq27421" - BQ27421 >>> - * "ti,bq27425" - BQ27425 >>> - * "ti,bq27426" - BQ27426 >>> - * "ti,bq27441" - BQ27441 >>> - * "ti,bq27621" - BQ27621 >>> -- reg: integer, I2C address of the fuel gauge. >>> - >>> -Optional properties: >>> -- monitored-battery: phandle of battery characteristics node >>> -    The fuel gauge uses the following battery properties: >>> -    + energy-full-design-microwatt-hours >>> -    + 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.txt >>> - >>> -Example: >>> - >>> -    bat: battery { >>> -        compatible = "simple-battery"; >>> -        voltage-min-design-microvolt = <3200000>; >>> -        energy-full-design-microwatt-hours = <5290000>; >>> -        charge-full-design-microamp-hours = <1430000>; >>> -    }; >>> - >>> -    bq27510g3: fuel-gauge@55 { >>> -        compatible = "ti,bq27510g3"; >>> -        reg = <0x55>; >>> -        monitored-battery = <&bat>; >>> -    }; >>> diff --git >>> a/Documentation/devicetree/bindings/power/supply/bq27xxx.yaml >>> b/Documentation/devicetree/bindings/power/supply/bq27xxx.yaml >>> new file mode 100644 >>> index 000000000000..6c53ee849004 >>> --- /dev/null >>> +++ b/Documentation/devicetree/bindings/power/supply/bq27xxx.yaml >>> @@ -0,0 +1,95 @@ >>> +# SPDX-License-Identifier: GPL-2.0 >>> +# Copyright (C) 2020 Texas Instruments Incorporated >>> +%YAML 1.2 >>> +--- >>> +$id: "http://devicetree.org/schemas/power/supply/bq27xxx.yaml#" >>> +$schema: "http://devicetree.org/meta-schemas/core.yaml#" >>> + >>> +title: TI BQ27XXX fuel gauge family >>> + >>> +maintainers: >>> +  - Pali Rohár >>> +  - Andrew F. Davis" > > Extra " at end of name. > Ack >>> +  - Sebastian Reichel >>> + >>> +description: | >>> +  Support various Texas Instruments fuel gauge devices that share >>> similar >>> +  register maps and power supply properties >>> + >>> +properties: >>> +  compatible: >>> +    enum: >>> +      - ti,bq27200 - BQ27200 >>> +      - ti,bq27210 - BQ27210 >>> +      - ti,bq27500 - deprecated, use revision specific property below >>> +      - ti,bq27510 - deprecated, use revision specific property below >>> +      - ti,bq27520 - deprecated, use revision specific property below >>> +      - ti,bq27500-1 - BQ27500/1 >>> +      - ti,bq27510g1 - BQ27510-g1 >>> +      - ti,bq27510g2 - BQ27510-g2 >>> +      - ti,bq27510g3 - BQ27510-g3 >>> +      - ti,bq27520g1 - BQ27520-g1 >>> +      - ti,bq27520g2 - BQ27520-g2 >>> +      - ti,bq27520g3 - BQ27520-g3 >>> +      - ti,bq27520g4 - BQ27520-g4 >>> +      - ti,bq27521 - BQ27521 >>> +      - ti,bq27530 - BQ27530 >>> +      - ti,bq27531 - BQ27531 >>> +      - ti,bq27541 - BQ27541 >>> +      - ti,bq27542 - BQ27542 >>> +      - ti,bq27546 - BQ27546 >>> +      - ti,bq27742 - BQ27742 >>> +      - ti,bq27545 - BQ27545 >>> +      - ti,bq27411 - BQ27411 >>> +      - ti,bq27421 - BQ27421 >>> +      - ti,bq27425 - BQ27425 >>> +      - ti,bq27426 - BQ27426 >>> +      - ti,bq27441 - BQ27441 >>> +      - ti,bq27621 - BQ27621 >>> + >>> +  reg: >>> +    maxItems: 1 >>> +    description: integer, I2C address of the fuel gauge. >>> + >>> +  monitored-battery: >>> +    description: phandle of battery characteristics node >>> + >>> +  energy-full-design-microwatt-hours: >>> +    description: | >>> +      See Documentation/devicetree/bindings/power/supply/battery.txt. >>> +      If this property is set then charge-full-design-microamp-hours >>> must be >>> +      set as well. > > These are properties of the battery node and should be described in > their binding, they are not part of the fuel gauge node here. OK.  I will add the explanation back from the original text file that these are used by the fuel gauge from the battery node. Dan