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 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 6E886C433F5 for ; Mon, 16 May 2022 23:53:59 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:Cc: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=72ATAYqSQNALrsBhtc2A+6HiorvSua5lrjWBlV87Awg=; b=pUbQ0YmRbbMOyQ xeAaIUyfBeKFXHjTngMLsc9XCovZmxKP9PXZAJP20yjt/0FRdqQTsK0ymYGc+1AFi8A7Fw0QmeLvF 8YvCEGGO+ofwjQmXJq3gp/Qye5wv6kHnd2xaOsXfcNPW6Pu5/8cKJ0nK/U6XuHVZe8pnSJNg2aVPC +/ecM2t2QmIiSrRnl+tv6IZCX7lljmhKFFnqEJCCKP9oOUgLqjn3LZwu2gzeSoyTE9ti7EkXd/C3Y YHoVG7ifFfazOwW+v3wp9hhPjtJw0uyiIl+TdJTWwcmzRm37Qw1G9gTqiz49y8aFGbVfcWW+FQgCj eh4UNFviVK6uK4sxDgFQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1nqkWH-00AskQ-4l; Mon, 16 May 2022 23:52:57 +0000 Received: from mail-oa1-f47.google.com ([209.85.160.47]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1nqkWD-00Asjb-Si for linux-arm-kernel@lists.infradead.org; Mon, 16 May 2022 23:52:55 +0000 Received: by mail-oa1-f47.google.com with SMTP id 586e51a60fabf-e5e433d66dso22288229fac.5 for ; Mon, 16 May 2022 16:52:52 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=oLYjtsgGlA07Qc3dBcMPR9s7GFGmrm0AkOOuD7W1saQ=; b=bE47a/6/6Xgf2NCnG7azLgdLOSIUDjYwkfQGHhJiwCpxMAlAEvAwQZiGVM0fT+5oRt MNmUWPC3Xh0RYX3a7tiyjtzcoO6Rq4W9qweVs8xEJG+EEGvE2lw/T0bifI7zp77rf/sI GKVnFZuPBKzebonl3vLY5NlVZz/ygNilJbfyBIZXULVNKQKs09OKwQfz6r84DinRlbqy 3uaMLeXosqKbSQrGBxoE+oYPqmuS4OSNYwQsDaJmVxwtxljTI6eoZFWZZLjjc86+VBa1 daDcQi1LzAryKXvB4/I/IdISca4vXwiLx3TfUC81PxvGwNLeZ3qAz9RyvlJPduOfowk2 i9Aw== X-Gm-Message-State: AOAM5330ouXeLRk1GND5hw/U5X1s9DZyPtAONm8RK/jlylsG9PYQaL10 5EDTrwoNLkyq43ZTNhS9wA== X-Google-Smtp-Source: ABdhPJzGVAd5OY/GykxaSm1uI0nwH0J0ngGxXZJsQ5IeSSSe+fV9RLKWsy4BBR/D9rZxTj9YblLnHg== X-Received: by 2002:a05:6870:b254:b0:ec:6ca4:c89f with SMTP id b20-20020a056870b25400b000ec6ca4c89fmr17070305oam.272.1652745171572; Mon, 16 May 2022 16:52:51 -0700 (PDT) Received: from robh.at.kernel.org (66-90-144-107.dyn.grandenetworks.net. [66.90.144.107]) by smtp.gmail.com with ESMTPSA id q9-20020aca5c09000000b00325cda1ffb6sm4263596oib.53.2022.05.16.16.52.50 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 16 May 2022 16:52:50 -0700 (PDT) Received: (nullmailer pid 3570060 invoked by uid 1000); Mon, 16 May 2022 23:52:49 -0000 Date: Mon, 16 May 2022 18:52:49 -0500 From: Rob Herring To: Valentin Caron Cc: Alessandro Zummo , Alexandre Belloni , Krzysztof Kozlowski , Alexandre Torgue , Gabriel Fernandez , Amelie Delaunay , linux-rtc@vger.kernel.org, devicetree@vger.kernel.org, linux-stm32@st-md-mailman.stormreply.com, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 1/6] dt-bindings: rtc: stm32: add st,lsco optional property to select output Message-ID: <20220516235249.GA3567294-robh@kernel.org> References: <20220504130233.330983-1-valentin.caron@foss.st.com> <20220504130233.330983-2-valentin.caron@foss.st.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20220504130233.330983-2-valentin.caron@foss.st.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220516_165253_969828_783716AD X-CRM114-Status: GOOD ( 25.39 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , 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 Wed, May 04, 2022 at 03:02:28PM +0200, Valentin Caron wrote: > From: Amelie Delaunay > > STM32 RTC has three output pins: RTC_OUT1, RTC_OUT2 or RTC_OUT2_RMP. > > RTC Low-Speed Clock Output (LSCO) can be output on RTC_OUT1 or > RTC_OUT2_RMP. > > This patch adds constants for RTC output bindings and adds st,lsco > optional property for stm32 rtc driver, to select and enable LSCO. > A pinctrl state is also optional to reserve pin for RTC output. > > Signed-off-by: Amelie Delaunay > Signed-off-by: Valentin Caron > --- > .../devicetree/bindings/rtc/st,stm32-rtc.yaml | 20 +++++++++++++++++++ > include/dt-bindings/rtc/rtc-stm32.h | 14 +++++++++++++ > 2 files changed, 34 insertions(+) > create mode 100644 include/dt-bindings/rtc/rtc-stm32.h > > diff --git a/Documentation/devicetree/bindings/rtc/st,stm32-rtc.yaml b/Documentation/devicetree/bindings/rtc/st,stm32-rtc.yaml > index 764717ce1873..56d46ea35c5d 100644 > --- a/Documentation/devicetree/bindings/rtc/st,stm32-rtc.yaml > +++ b/Documentation/devicetree/bindings/rtc/st,stm32-rtc.yaml > @@ -52,6 +52,13 @@ properties: > override default rtc_ck parent clock phandle of the new parent clock of rtc_ck > maxItems: 1 > > + st,lsco: > + $ref: "/schemas/types.yaml#/definitions/uint32" > + description: | > + To select and enable RTC Low Speed Clock Output. > + Refer to for the supported values. > + Pinctrl state named "default" may be defined to reserve pin for RTC output. > + > allOf: > - if: > properties: > @@ -65,6 +72,9 @@ allOf: > minItems: 1 > maxItems: 1 > > + st,lsco: > + maxItems: 0 If disallowing the property is what you wanted, then 'st,lsco: false' is the way. 'maxItems: 0' is never correct. > + > clock-names: false > > required: > @@ -82,6 +92,9 @@ allOf: > minItems: 2 > maxItems: 2 > > + st,lsco: > + maxItems: 0 > + > required: > - clock-names > - st,syscfg > @@ -101,6 +114,9 @@ allOf: > assigned-clocks: false > assigned-clock-parents: false > > + st,lsco: > + maxItems: 1 > + > required: > - clock-names > > @@ -130,12 +146,16 @@ examples: > - | > #include > #include > + #include > rtc@5c004000 { > compatible = "st,stm32mp1-rtc"; > reg = <0x5c004000 0x400>; > clocks = <&rcc RTCAPB>, <&rcc RTC>; > clock-names = "pclk", "rtc_ck"; > interrupts = ; > + st,lsco = ; > + pinctrl-0 = <&rtc_out2_rmp_pins_a>; > + pinctrl-names = "default"; > }; > > ... > diff --git a/include/dt-bindings/rtc/rtc-stm32.h b/include/dt-bindings/rtc/rtc-stm32.h > new file mode 100644 > index 000000000000..2fd78c2e62d4 > --- /dev/null > +++ b/include/dt-bindings/rtc/rtc-stm32.h > @@ -0,0 +1,14 @@ > +/* SPDX-License-Identifier: GPL-2.0 */ > +/* > + * This header provides constants for STM32_RTC bindings. > + */ > + > +#ifndef _DT_BINDINGS_RTC_RTC_STM32_H > +#define _DT_BINDINGS_RTC_RTC_STM32_H > + > +#define RTC_NO_OUT 0 > +#define RTC_OUT1 1 > +#define RTC_OUT2 2 > +#define RTC_OUT2_RMP 3 > + > +#endif > -- > 2.25.1 > > _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel