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=-10.5 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH, MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED 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 742B2C4727F for ; Wed, 30 Sep 2020 10:02:19 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 0676B2074A for ; Wed, 30 Sep 2020 10:02:19 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="SakBtdvu" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 0676B2074A Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=bootlin.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References:Message-ID: Subject:To:From:Date:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=FKCkQ1CPkFWNngfDTfW42MVC87vfXOcdmqTvLz1NOZ8=; b=SakBtdvuTfAxSGX6IgdOa28Pb KThF0jV1UagC9cgZ4WY1Siemjq3mjUuzm4T6hn3Bi3u3TFCVSmU+zH6U7uetLSFYGhyeODnSM2n+B YBFBydJLzGs+NQS9q+7YZFmvEDGs4wUO1QeFcthgKqnh7CQbO2Na7rTQJZ72CVcafHzNUy5BwwGsr oAw1irPxB79OLFFiKNKeCe1sRwqcVKSs9wqd+lIcXD2DKVB6O/cXOB0pNLQ0AiKcOmC0kJV/XFnBT o5KZvkE1KW458u1YFjRgFRFpIdsRz2zoMb8x2b9OBLPPxewIdpZp6BKH9CuPNZMgcNOSLpRCXC8JB VdbwyBTng==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1kNYv0-0002ry-BN; Wed, 30 Sep 2020 10:01:02 +0000 Received: from relay12.mail.gandi.net ([217.70.178.232]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1kNYux-0002r5-3P for linux-arm-kernel@lists.infradead.org; Wed, 30 Sep 2020 10:01:00 +0000 Received: from localhost (lfbn-lyo-1-1908-165.w90-65.abo.wanadoo.fr [90.65.88.165]) (Authenticated sender: alexandre.belloni@bootlin.com) by relay12.mail.gandi.net (Postfix) with ESMTPSA id 09FF3200011; Wed, 30 Sep 2020 10:00:55 +0000 (UTC) Date: Wed, 30 Sep 2020 12:00:55 +0200 From: Alexandre Belloni To: Rob Herring Subject: Re: [PATCH 1/4] dt-bindings: microchip: atmel,at91rm9200-tcb: add atmel,tcb-pwm Message-ID: <20200930100055.GF2804081@piout.net> References: <20200820225546.2246517-1-alexandre.belloni@bootlin.com> <20200820225546.2246517-2-alexandre.belloni@bootlin.com> <20200908204834.GA886652@bogus> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20200908204834.GA886652@bogus> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200930_060059_387667_0A803309 X-CRM114-Status: GOOD ( 26.30 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-pwm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Thierry Reding , Uwe =?iso-8859-1?Q?Kleine-K=F6nig?= , linux-arm-kernel@lists.infradead.org Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On 08/09/2020 14:48:34-0600, Rob Herring wrote: > On Fri, Aug 21, 2020 at 12:55:43AM +0200, Alexandre Belloni wrote: > > Move the TCB pwm nodes under their parent and move its documentation to the > > main file. > > > > Signed-off-by: Alexandre Belloni > > --- > > Cc: Rob Herring > > > > .../devicetree/bindings/pwm/atmel-tcb-pwm.txt | 16 ---------- > > .../soc/microchip/atmel,at91rm9200-tcb.yaml | 31 ++++++++++++++++++- > > 2 files changed, 30 insertions(+), 17 deletions(-) > > delete mode 100644 Documentation/devicetree/bindings/pwm/atmel-tcb-pwm.txt > > > > diff --git a/Documentation/devicetree/bindings/pwm/atmel-tcb-pwm.txt b/Documentation/devicetree/bindings/pwm/atmel-tcb-pwm.txt > > deleted file mode 100644 > > index 985fcc65f8c4..000000000000 > > --- a/Documentation/devicetree/bindings/pwm/atmel-tcb-pwm.txt > > +++ /dev/null > > @@ -1,16 +0,0 @@ > > -Atmel TCB PWM controller > > - > > -Required properties: > > -- compatible: should be "atmel,tcb-pwm" > > -- #pwm-cells: should be 3. See pwm.yaml in this directory for a description of > > - the cells format. The only third cell flag supported by this binding is > > - PWM_POLARITY_INVERTED. > > -- tc-block: The Timer Counter block to use as a PWM chip. > > What happened to 'tc-block'? Commit message should mention why it is > gone. > > > - > > -Example: > > - > > -pwm { > > - compatible = "atmel,tcb-pwm"; > > - #pwm-cells = <3>; > > - tc-block = <1>; > > -}; > > diff --git a/Documentation/devicetree/bindings/soc/microchip/atmel,at91rm9200-tcb.yaml b/Documentation/devicetree/bindings/soc/microchip/atmel,at91rm9200-tcb.yaml > > index 55fffae05dcf..a51adfdb58f6 100644 > > --- a/Documentation/devicetree/bindings/soc/microchip/atmel,at91rm9200-tcb.yaml > > +++ b/Documentation/devicetree/bindings/soc/microchip/atmel,at91rm9200-tcb.yaml > > @@ -59,6 +59,7 @@ patternProperties: > > items: > > - enum: > > - atmel,tcb-timer > > + - atmel,tcb-pwm > > - microchip,tcb-capture > > reg: > > description: > > @@ -68,11 +69,33 @@ patternProperties: > > > > minItems: 1 > > maxItems: 3 > > + required: > > + - compatible > > + - reg > > + > > + "^pwm@[0-2]$": > > + description: The timer block channels that are used as PWMs. > > + $ref: ../../pwm/pwm.yaml# > > + type: object > > + properties: > > + compatible: > > + const: atmel,tcb-pwm > > + reg: > > + description: > > + TCB channel to use for this PWM. > > enum: [ 0, 1, 2 ] > This does not work: Documentation/devicetree/bindings/soc/microchip/atmel,at91rm9200-tcb.yaml: patternProperties:^pwm@[0-2]$:properties:reg:enum: False schema does not allow [0, 1, 2] I guess it is because reg is of type uint32-matrix. I'm not sure there is a point in adding it in the first place since the unit-address is already limited to [0-2] and so reg will also be [0-2] > > + > > + maxItems: 1 > > + "#pwm-cells": > > + description: > > + The only third cell flag supported by this binding is > > + PWM_POLARITY_INVERTED. > > + const: 3 > > > > required: > > - compatible > > - reg > > additionalProperties: false > > > > > + > > allOf: > > - if: > > properties: > > @@ -158,7 +181,13 @@ examples: > > compatible = "atmel,tcb-timer"; > > reg = <1>; > > }; > > - }; > > + > > + pwm@2 { > > + compatible = "atmel,tcb-pwm"; > > + reg = <2>; > > + #pwm-cells = <3>; > > + }; > > + }; > > /* TCB0 Capture with QDEC: */ > > timer@f800c000 { > > compatible = "atmel,at91rm9200-tcb", "simple-mfd", "syscon"; > > -- > > 2.26.2 > > -- Alexandre Belloni, Bootlin Embedded Linux and Kernel engineering https://bootlin.com _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel