From: Rob Herring <robh@kernel.org>
To: Valentin Caron <valentin.caron@foss.st.com>
Cc: Alessandro Zummo <a.zummo@towertech.it>,
Alexandre Belloni <alexandre.belloni@bootlin.com>,
Krzysztof Kozlowski <krzk+dt@kernel.org>,
Alexandre Torgue <alexandre.torgue@foss.st.com>,
Gabriel Fernandez <gabriel.fernandez@foss.st.com>,
Amelie Delaunay <amelie.delaunay@foss.st.com>,
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
Date: Mon, 16 May 2022 18:52:49 -0500 [thread overview]
Message-ID: <20220516235249.GA3567294-robh@kernel.org> (raw)
In-Reply-To: <20220504130233.330983-2-valentin.caron@foss.st.com>
On Wed, May 04, 2022 at 03:02:28PM +0200, Valentin Caron wrote:
> From: Amelie Delaunay <amelie.delaunay@foss.st.com>
>
> 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 <amelie.delaunay@foss.st.com>
> Signed-off-by: Valentin Caron <valentin.caron@foss.st.com>
> ---
> .../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 <include/dt-bindings/rtc/rtc-stm32.h> 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 <dt-bindings/interrupt-controller/arm-gic.h>
> #include <dt-bindings/clock/stm32mp1-clks.h>
> + #include <dt-bindings/rtc/rtc-stm32.h>
> rtc@5c004000 {
> compatible = "st,stm32mp1-rtc";
> reg = <0x5c004000 0x400>;
> clocks = <&rcc RTCAPB>, <&rcc RTC>;
> clock-names = "pclk", "rtc_ck";
> interrupts = <GIC_SPI 3 IRQ_TYPE_LEVEL_HIGH>;
> + st,lsco = <RTC_OUT2_RMP>;
> + 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
>
>
WARNING: multiple messages have this Message-ID (diff)
From: Rob Herring <robh@kernel.org>
To: Valentin Caron <valentin.caron@foss.st.com>
Cc: Alessandro Zummo <a.zummo@towertech.it>,
Alexandre Belloni <alexandre.belloni@bootlin.com>,
Krzysztof Kozlowski <krzk+dt@kernel.org>,
Alexandre Torgue <alexandre.torgue@foss.st.com>,
Gabriel Fernandez <gabriel.fernandez@foss.st.com>,
Amelie Delaunay <amelie.delaunay@foss.st.com>,
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
Date: Mon, 16 May 2022 18:52:49 -0500 [thread overview]
Message-ID: <20220516235249.GA3567294-robh@kernel.org> (raw)
In-Reply-To: <20220504130233.330983-2-valentin.caron@foss.st.com>
On Wed, May 04, 2022 at 03:02:28PM +0200, Valentin Caron wrote:
> From: Amelie Delaunay <amelie.delaunay@foss.st.com>
>
> 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 <amelie.delaunay@foss.st.com>
> Signed-off-by: Valentin Caron <valentin.caron@foss.st.com>
> ---
> .../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 <include/dt-bindings/rtc/rtc-stm32.h> 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 <dt-bindings/interrupt-controller/arm-gic.h>
> #include <dt-bindings/clock/stm32mp1-clks.h>
> + #include <dt-bindings/rtc/rtc-stm32.h>
> rtc@5c004000 {
> compatible = "st,stm32mp1-rtc";
> reg = <0x5c004000 0x400>;
> clocks = <&rcc RTCAPB>, <&rcc RTC>;
> clock-names = "pclk", "rtc_ck";
> interrupts = <GIC_SPI 3 IRQ_TYPE_LEVEL_HIGH>;
> + st,lsco = <RTC_OUT2_RMP>;
> + 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
next prev parent reply other threads:[~2022-05-16 23:53 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-05-04 13:02 [PATCH 0/6] rtc: stm32: add alarm out and LSCO features Valentin Caron
2022-05-04 13:02 ` Valentin Caron
2022-05-04 13:02 ` [PATCH 1/6] dt-bindings: rtc: stm32: add st,lsco optional property to select output Valentin Caron
2022-05-04 13:02 ` [PATCH 1/6] dt-bindings: rtc: stm32: add st, lsco " Valentin Caron
2022-05-16 23:52 ` Rob Herring [this message]
2022-05-16 23:52 ` [PATCH 1/6] dt-bindings: rtc: stm32: add st,lsco " Rob Herring
2022-05-04 13:06 ` [PATCH 2/6] dt-bindings: rtc: stm32: add alarm A out " Valentin Caron
2022-05-04 13:06 ` Valentin Caron
2022-05-04 15:42 ` Rob Herring
2022-05-04 15:42 ` Rob Herring
2022-05-04 20:27 ` Alexandre Belloni
2022-05-04 20:27 ` Alexandre Belloni
2022-05-23 12:34 ` Valentin CARON
2022-05-23 12:34 ` Valentin CARON
2022-06-24 8:35 ` Valentin CARON
2022-06-24 8:35 ` Valentin CARON
2022-07-22 16:02 ` Alexandre Belloni
2022-07-22 16:02 ` Alexandre Belloni
2022-05-04 13:06 ` [PATCH 3/6] rtc: stm32: add Low Speed Clock Output (LSCO) support Valentin Caron
2022-05-04 13:06 ` Valentin Caron
2022-05-04 13:06 ` [PATCH 4/6] rtc: stm32: add alarm A out feature Valentin Caron
2022-05-04 13:06 ` Valentin Caron
2022-05-04 13:06 ` [PATCH 5/6] ARM: dts: stm32: add RTC LSCO support on stm32mp157c-dk2 Valentin Caron
2022-05-04 13:06 ` Valentin Caron
2022-05-04 13:06 ` [PATCH 6/6] ARM: dts: stm32: add RTC LSCO support on stm32mp135f-dk Valentin Caron
2022-05-04 13:06 ` Valentin Caron
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20220516235249.GA3567294-robh@kernel.org \
--to=robh@kernel.org \
--cc=a.zummo@towertech.it \
--cc=alexandre.belloni@bootlin.com \
--cc=alexandre.torgue@foss.st.com \
--cc=amelie.delaunay@foss.st.com \
--cc=devicetree@vger.kernel.org \
--cc=gabriel.fernandez@foss.st.com \
--cc=krzk+dt@kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rtc@vger.kernel.org \
--cc=linux-stm32@st-md-mailman.stormreply.com \
--cc=valentin.caron@foss.st.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.