Received: by 2002:a25:1506:0:0:0:0:0 with SMTP id 6csp2009858ybv; Thu, 6 Feb 2020 14:07:53 -0800 (PST) X-Google-Smtp-Source: APXvYqw2NzUtgU2+hB9IFPxxO9UvCAnodv3NmWVghVXGE166gukKhusLNTRTopXSchT2ZOAg0WwX X-Received: by 2002:a9d:7cd9:: with SMTP id r25mr205023otn.326.1581026873489; Thu, 06 Feb 2020 14:07:53 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1581026873; cv=none; d=google.com; s=arc-20160816; b=Mzvtam7C4227wZ+r7oE63eWEw+kocHyyDhBzrwtN5qsVpfAwfijfbuxx2T5JqqOkHN PmJv2AKjSTjV/c7WrcXl2ka56LuQJKl75B/YL6k4ffsP030zgoJrN477mCigzIp+nWWT rpyxktMY+ZBCRcgttAxE5jbgkzDCf51ve2sJdHlZfVlOli4a4spJdvQnek9fNv0wIkxQ YFA+DkLHO3sybwZBa9clDUssJ9wWfzrxtUehiEvzu4E9hOgyHKmwGYKhg2gf9EpH0uwl 5fuFdAm0Bo44Lk/oREzPiUGmQOBRqIkSwWsZTHoMe5FgwDoBLtKY2tw3p/Ib1P/p1yw3 Y4Nw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=l+xsy+e2MiIYtNBrIyrqdyfGDG8iY0hLdKQLctRhiwQ=; b=u5p16tEYxKGBnR1va0Eld+GSZshgF3f44haUdByH5UZf8g+tVlkB3uQ2eyYQRUWcDD iLVqXs3ShNKJ7FVWr86KOEYgF3+XjFulXyZUvLGNNGdLV7ntDy6eyAXkeOjkYDtaUlm7 YY+1Wna+f2Zz+ObBxEKnOaswu4XsVKacE0A5o/RWsCBJqwehBzvKnKiUjJrmftm4/mEv 2Ce11zgIPVD/fY/FDfAdR+oVN80KOtA/RlKrQ+EkK8mjRInURHO32uYrRYshy5BP8vN5 0FWPoIgFuxrTvav9Qc0mcQctQUcWCar3KBqTh3iq32lSPv5GTSyuBD9WLVFy00OhkER4 ac3Q== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id i12si533803otk.215.2020.02.06.14.07.40; Thu, 06 Feb 2020 14:07:53 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727527AbgBFWGm (ORCPT + 99 others); Thu, 6 Feb 2020 17:06:42 -0500 Received: from mail-pg1-f194.google.com ([209.85.215.194]:37081 "EHLO mail-pg1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726765AbgBFWGm (ORCPT ); Thu, 6 Feb 2020 17:06:42 -0500 Received: by mail-pg1-f194.google.com with SMTP id z12so28064pgl.4; Thu, 06 Feb 2020 14:06:41 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=l+xsy+e2MiIYtNBrIyrqdyfGDG8iY0hLdKQLctRhiwQ=; b=iuzMUBjJ99Yco7KgcNzAC0Jeor9ar8XBhCeiRZtt7R+L3fgz52R6wwoL6GBPJBaQLg LjmFC0yZycVKZvq9oQbMmgHdc6qoQtrXD1Vio4F0HAQ/+qaak/Icysaw+QPrLQs8hVsR r5Kd+UbfDXLhrfwZ6sOshNGdOagfWSwmJgnYuX0IipDum7vc2d1rxqyxIHJlHB6G9oO1 RTHekq30Hv45DWNvbNKMbS5DH0+/B8CDY1ZSSnKjX8+hyf/mF9hSJ9TWpK3OA8LkwSiW XfqAb/2E1MGZPIalnJ6cOl7+3dz/PZTAJfuiRqXcP/ru1yXlzmb/AJ8Hph7ZYOhHfuL9 faCQ== X-Gm-Message-State: APjAAAVxwMB1Ng63Q6AzqxXqp6rJaXfP0qk87aB44c3wkedHXqffyO4n h7FgsZMeo+ViXrNObSm2RQ== X-Received: by 2002:aa7:8582:: with SMTP id w2mr6041556pfn.89.1581026801476; Thu, 06 Feb 2020 14:06:41 -0800 (PST) Received: from rob-hp-laptop (63-158-47-182.dia.static.qwest.net. [63.158.47.182]) by smtp.gmail.com with ESMTPSA id i64sm373190pgc.51.2020.02.06.14.06.39 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 06 Feb 2020 14:06:40 -0800 (PST) Received: (nullmailer pid 2119 invoked by uid 1000); Thu, 06 Feb 2020 22:06:38 -0000 Date: Thu, 6 Feb 2020 15:06:38 -0700 From: Rob Herring To: Stephen Boyd Cc: Andy Gross , Bjorn Andersson , Kiran Gunda , Lee Jones , Mark Rutland , devicetree@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org, rnayak@codeaurora.org Subject: Re: [PATCH V3 1/2] mfd: qcom-spmi-pmic: Convert bindings to .yaml format Message-ID: <20200206220638.GA28227@bogus> References: <1580997328-16365-1-git-send-email-kgunda@codeaurora.org> <5e3c63d0.1c69fb81.c2bba.0957@mx.google.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <5e3c63d0.1c69fb81.c2bba.0957@mx.google.com> User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Feb 06, 2020 at 11:06:55AM -0800, Stephen Boyd wrote: > Quoting Kiran Gunda (2020-02-06 05:55:26) > > Convert the bindings from .txt to .yaml format. > > > > Signed-off-by: Kiran Gunda > > --- > > Did something change? Is there a cover letter? > > > diff --git a/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml b/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml > > new file mode 100644 > > index 0000000..affc169 > > --- /dev/null > > +++ b/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml > > @@ -0,0 +1,115 @@ > > +# SPDX-License-Identifier: GPL-2.0-only > > +%YAML 1.2 > > +--- > > +$id: http://devicetree.org/schemas/bindings/mfd/qcom,spmi-pmic.yaml# > > +$schema: http://devicetree.org/meta-schemas/core.yaml# > > + > > +title: Qualcomm SPMI PMICs multi-function device bindings > > + > > +maintainers: > > + - Lee Jones > > + - Stephen Boyd > > Please change this to sboyd@kernel.org Should be the h/w owner, not applier of changes. > > > + > > +description: | > > + The Qualcomm SPMI series presently includes PM8941, PM8841 and PMA8084 > > + PMICs. These PMICs use a QPNP scheme through SPMI interface. > > This first sentence will need continual updating. Please drop it. > > > + QPNP is effectively a partitioning scheme for dividing the SPMI extended > > + register space up into logical pieces, and set of fixed register > > + locations/definitions within these regions, with some of these regions > > + specifically used for interrupt handling. > > + > > + The QPNP PMICs are used with the Qualcomm Snapdragon series SoCs, and are > > + interfaced to the chip via the SPMI (System Power Management Interface) bus. > > + Support for multiple independent functions are implemented by splitting the > > + 16-bit SPMI slave address space into 256 smaller fixed-size regions, 256 bytes > > + each. A function can consume one or more of these fixed-size register regions. > > + > > +properties: > > + compatible: > > + enum: > > + - qcom,pm8941 > > + - qcom,pm8841 > > + - qcom,pma8084 > > + - qcom,pm8019 > > + - qcom,pm8226 > > + - qcom,pm8110 > > + - qcom,pma8084 > > + - qcom,pmi8962 > > + - qcom,pmd9635 > > + - qcom,pm8994 > > + - qcom,pmi8994 > > + - qcom,pm8916 > > + - qcom,pm8004 > > + - qcom,pm8909 > > + - qcom,pm8950 > > + - qcom,pmi8950 > > + - qcom,pm8998 > > + - qcom,pmi8998 > > + - qcom,pm8005 > > + - qcom,spmi-pmic > > I think we want qcom,spmi-pmic to be there always. To do that we need it > to look like: > > compatible: > items: > enum: > - qcom,pm8941 > ... > enum: > - qcom,spmi-pmic Yes, but missing '-' before the enum's. > > > + > > + reg: > > + maxItems: 1 > > + description: > > + Specifies the SPMI USID slave address for this device. > > + For more information see Documentation/devicetree/bindings/spmi/spmi.txt > > + > > +patternProperties: > > + "^.*@[0-9a-f]+$": You are going to need to define the specific child nodes with the schemas for them, but a SPMI bus schema may be useful. > > + type: object > > + description: > > + Each child node of SPMI slave id represents a function of the PMIC. In the > > + example below the rtc device node represents a peripheral of pm8941 > > + SID = 0. The regulator device node represents a peripheral of pm8941 SID = 1. > > + > > + properties: > > + compatible: > > + description: > > + Compatible of the PMIC device. > > + > > + interrupts: > > + maxItems: 2 > > + description: > > + Interrupts are specified as a 4-tuple. For more information > > + see Documentation/devicetree/bindings/spmi/qcom,spmi-pmic-arb.txt > > Just make this bindings/spmi/qcom,spmi-pmic-arb.txt so that we don't > have to worry about it. Why is max items 2? Isn't it 4? Is this property > supposed to be specified at all? > > > + > > + interrupt-names: > > + description: > > + Corresponding interrupt name to the interrupts property > > Does this need to be specified either? > > > + > > + required: > > + - compatible > > + > > +required: > > + - compatible > > + - reg > > + > > +examples: > > + - | > > + spmi { > > + compatible = "qcom,spmi-pmic-arb"; > > + #address-cells = <2>; > > + #size-cells = <0>; > > + > > + pm8941@0 { > > pmic@0 > > > + compatible = "qcom,pm8941"; > > + reg = <0x0 0x0>; > > Why not include the header file to get the SPMI_USID macro? > > > + > > + rtc { > > + compatible = "qcom,rtc"; > > + interrupts = <0x0 0x61 0x1 0x1>; > > + interrupt-names = "alarm"; > > + }; > > + }; > > + > > + pm8941@1 { > > pmic@1 > > > + compatible = "qcom,pm8941"; > > + reg = <0x1 0x0>; > > + > > + regulator { > > + compatible = "qcom,regulator"; > > + regulator-name = "8941_boost"; > > + }; > > + }; > > + }; > > +... > > -- > > The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum, > > a Linux Foundation Collaborative Project