* [PATCH] dt-bindings: rtc: pcf2123: convert to YAML
@ 2023-09-10 11:00 Javier Carrasco
2023-09-10 12:17 ` Alexandre Belloni
2023-09-11 6:17 ` Krzysztof Kozlowski
0 siblings, 2 replies; 6+ messages in thread
From: Javier Carrasco @ 2023-09-10 11:00 UTC (permalink / raw)
To: Alessandro Zummo, Alexandre Belloni, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Chris Verges
Cc: linux-rtc, devicetree, linux-kernel, Javier Carrasco
Convert the existing txt binding to the preferred YAML format.
The pcf2123 node may contain SPI settings such as spi-cs-high and
spi-max-frequency, which keeps it from being added to the trivial-rtc
binding with its current definition. Add a reference to
spi-peripheral-props.yaml to account for that.
The "interrupts" property was missing in the binding although it is
already supported. Add the missing property in the new binding.
Signed-off-by: Javier Carrasco <javier.carrasco.cruz@gmail.com>
---
.../devicetree/bindings/rtc/nxp,pcf2123.yaml | 45 ++++++++++++++++++++++
.../devicetree/bindings/rtc/nxp,rtc-2123.txt | 17 --------
2 files changed, 45 insertions(+), 17 deletions(-)
diff --git a/Documentation/devicetree/bindings/rtc/nxp,pcf2123.yaml b/Documentation/devicetree/bindings/rtc/nxp,pcf2123.yaml
new file mode 100644
index 000000000000..013e5e5dc0ae
--- /dev/null
+++ b/Documentation/devicetree/bindings/rtc/nxp,pcf2123.yaml
@@ -0,0 +1,45 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/rtc/nxp,pcf2123.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: NXP PCF2123 SPI Real Time Clock
+
+maintainers:
+ - Chris Verges <chrisv@cyberswitching.com>
+
+allOf:
+ - $ref: /schemas/spi/spi-peripheral-props.yaml#
+ - $ref: rtc.yaml#
+
+properties:
+ compatible:
+ enum:
+ - nxp,pcf2123
+
+ reg:
+ maxItems: 1
+
+ interrupts:
+ maxItems: 1
+
+required:
+ - compatible
+ - reg
+
+unevaluatedProperties: false
+
+examples:
+ - |
+ spi {
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ rtc@3 {
+ compatible = "nxp,pcf2123";
+ reg = <3>;
+ spi-cs-high;
+ };
+ };
+...
diff --git a/Documentation/devicetree/bindings/rtc/nxp,rtc-2123.txt b/Documentation/devicetree/bindings/rtc/nxp,rtc-2123.txt
deleted file mode 100644
index 7371f525a687..000000000000
--- a/Documentation/devicetree/bindings/rtc/nxp,rtc-2123.txt
+++ /dev/null
@@ -1,17 +0,0 @@
-NXP PCF2123 SPI Real Time Clock
-
-Required properties:
-- compatible: should be: "nxp,pcf2123"
- or "microcrystal,rv2123"
-- reg: should be the SPI slave chipselect address
-
-Optional properties:
-- spi-cs-high: PCF2123 needs chipselect high
-
-Example:
-
-pcf2123: rtc@3 {
- compatible = "nxp,pcf2123"
- reg = <3>
- spi-cs-high;
-};
---
base-commit: 535a265d7f0dd50d8c3a4f8b4f3a452d56bd160f
change-id: 20230907-topic-pcf2123_yaml-2ce57f4e77d7
Best regards,
--
Javier Carrasco <javier.carrasco.cruz@gmail.com>
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH] dt-bindings: rtc: pcf2123: convert to YAML
2023-09-10 11:00 [PATCH] dt-bindings: rtc: pcf2123: convert to YAML Javier Carrasco
@ 2023-09-10 12:17 ` Alexandre Belloni
2023-09-10 12:31 ` Javier Carrasco
2023-09-11 8:43 ` Javier Carrasco
2023-09-11 6:17 ` Krzysztof Kozlowski
1 sibling, 2 replies; 6+ messages in thread
From: Alexandre Belloni @ 2023-09-10 12:17 UTC (permalink / raw)
To: Javier Carrasco
Cc: Alessandro Zummo, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Chris Verges, linux-rtc, devicetree, linux-kernel
On 10/09/2023 13:00:27+0200, Javier Carrasco wrote:
> Convert the existing txt binding to the preferred YAML format.
>
> The pcf2123 node may contain SPI settings such as spi-cs-high and
> spi-max-frequency, which keeps it from being added to the trivial-rtc
> binding with its current definition. Add a reference to
> spi-peripheral-props.yaml to account for that.
>
> The "interrupts" property was missing in the binding although it is
> already supported. Add the missing property in the new binding.
>
> Signed-off-by: Javier Carrasco <javier.carrasco.cruz@gmail.com>
> ---
> .../devicetree/bindings/rtc/nxp,pcf2123.yaml | 45 ++++++++++++++++++++++
> .../devicetree/bindings/rtc/nxp,rtc-2123.txt | 17 --------
> 2 files changed, 45 insertions(+), 17 deletions(-)
>
> diff --git a/Documentation/devicetree/bindings/rtc/nxp,pcf2123.yaml b/Documentation/devicetree/bindings/rtc/nxp,pcf2123.yaml
> new file mode 100644
> index 000000000000..013e5e5dc0ae
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/rtc/nxp,pcf2123.yaml
> @@ -0,0 +1,45 @@
> +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/rtc/nxp,pcf2123.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: NXP PCF2123 SPI Real Time Clock
> +
> +maintainers:
> + - Chris Verges <chrisv@cyberswitching.com>
Is Chris willing to maintain the binding?
> +
> +allOf:
> + - $ref: /schemas/spi/spi-peripheral-props.yaml#
> + - $ref: rtc.yaml#
> +
> +properties:
> + compatible:
> + enum:
> + - nxp,pcf2123
> +
> + reg:
> + maxItems: 1
> +
> + interrupts:
> + maxItems: 1
> +
> +required:
> + - compatible
> + - reg
> +
> +unevaluatedProperties: false
> +
> +examples:
> + - |
> + spi {
> + #address-cells = <1>;
> + #size-cells = <0>;
> +
> + rtc@3 {
> + compatible = "nxp,pcf2123";
> + reg = <3>;
> + spi-cs-high;
> + };
> + };
> +...
> diff --git a/Documentation/devicetree/bindings/rtc/nxp,rtc-2123.txt b/Documentation/devicetree/bindings/rtc/nxp,rtc-2123.txt
> deleted file mode 100644
> index 7371f525a687..000000000000
> --- a/Documentation/devicetree/bindings/rtc/nxp,rtc-2123.txt
> +++ /dev/null
> @@ -1,17 +0,0 @@
> -NXP PCF2123 SPI Real Time Clock
> -
> -Required properties:
> -- compatible: should be: "nxp,pcf2123"
> - or "microcrystal,rv2123"
> -- reg: should be the SPI slave chipselect address
> -
> -Optional properties:
> -- spi-cs-high: PCF2123 needs chipselect high
> -
> -Example:
> -
> -pcf2123: rtc@3 {
> - compatible = "nxp,pcf2123"
> - reg = <3>
> - spi-cs-high;
> -};
>
> ---
> base-commit: 535a265d7f0dd50d8c3a4f8b4f3a452d56bd160f
> change-id: 20230907-topic-pcf2123_yaml-2ce57f4e77d7
>
> Best regards,
> --
> Javier Carrasco <javier.carrasco.cruz@gmail.com>
>
--
Alexandre Belloni, co-owner and COO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] dt-bindings: rtc: pcf2123: convert to YAML
2023-09-10 12:17 ` Alexandre Belloni
@ 2023-09-10 12:31 ` Javier Carrasco
2023-09-11 8:43 ` Javier Carrasco
1 sibling, 0 replies; 6+ messages in thread
From: Javier Carrasco @ 2023-09-10 12:31 UTC (permalink / raw)
To: Alexandre Belloni
Cc: Alessandro Zummo, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Chris Verges, linux-rtc, devicetree, linux-kernel
Hi Alexandre,
On 10.09.23 14:17, Alexandre Belloni wrote:
> On 10/09/2023 13:00:27+0200, Javier Carrasco wrote:
>> Convert the existing txt binding to the preferred YAML format.
>>
>> The pcf2123 node may contain SPI settings such as spi-cs-high and
>> spi-max-frequency, which keeps it from being added to the trivial-rtc
>> binding with its current definition. Add a reference to
>> spi-peripheral-props.yaml to account for that.
>>
>> The "interrupts" property was missing in the binding although it is
>> already supported. Add the missing property in the new binding.
>>
>> Signed-off-by: Javier Carrasco <javier.carrasco.cruz@gmail.com>
>> ---
>> .../devicetree/bindings/rtc/nxp,pcf2123.yaml | 45 ++++++++++++++++++++++
>> .../devicetree/bindings/rtc/nxp,rtc-2123.txt | 17 --------
>> 2 files changed, 45 insertions(+), 17 deletions(-)
>>
>> diff --git a/Documentation/devicetree/bindings/rtc/nxp,pcf2123.yaml b/Documentation/devicetree/bindings/rtc/nxp,pcf2123.yaml
>> new file mode 100644
>> index 000000000000..013e5e5dc0ae
>> --- /dev/null
>> +++ b/Documentation/devicetree/bindings/rtc/nxp,pcf2123.yaml
>> @@ -0,0 +1,45 @@
>> +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
>> +%YAML 1.2
>> +---
>> +$id: http://devicetree.org/schemas/rtc/nxp,pcf2123.yaml#
>> +$schema: http://devicetree.org/meta-schemas/core.yaml#
>> +
>> +title: NXP PCF2123 SPI Real Time Clock
>> +
>> +maintainers:
>> + - Chris Verges <chrisv@cyberswitching.com>
>
> Is Chris willing to maintain the binding?
>
I added the driver's author as the binding's maintainer because I
thought it makes sense and it would be more consistent if the driver
gets new additions. But I did not consider that the driver's maintainer
might not be willing to be the driver binding's maintainer. If that is
the case, sorry for the assumption! I can add myself as a maintainer and
send a v2.
Chris is in cc as well so I will wait for his opinion.
>> +
>> +allOf:
>> + - $ref: /schemas/spi/spi-peripheral-props.yaml#
>> + - $ref: rtc.yaml#
>> +
>> +properties:
>> + compatible:
>> + enum:
>> + - nxp,pcf2123
>> +
>> + reg:
>> + maxItems: 1
>> +
>> + interrupts:
>> + maxItems: 1
>> +
>> +required:
>> + - compatible
>> + - reg
>> +
>> +unevaluatedProperties: false
>> +
>> +examples:
>> + - |
>> + spi {
>> + #address-cells = <1>;
>> + #size-cells = <0>;
>> +
>> + rtc@3 {
>> + compatible = "nxp,pcf2123";
>> + reg = <3>;
>> + spi-cs-high;
>> + };
>> + };
>> +...
>> diff --git a/Documentation/devicetree/bindings/rtc/nxp,rtc-2123.txt b/Documentation/devicetree/bindings/rtc/nxp,rtc-2123.txt
>> deleted file mode 100644
>> index 7371f525a687..000000000000
>> --- a/Documentation/devicetree/bindings/rtc/nxp,rtc-2123.txt
>> +++ /dev/null
>> @@ -1,17 +0,0 @@
>> -NXP PCF2123 SPI Real Time Clock
>> -
>> -Required properties:
>> -- compatible: should be: "nxp,pcf2123"
>> - or "microcrystal,rv2123"
>> -- reg: should be the SPI slave chipselect address
>> -
>> -Optional properties:
>> -- spi-cs-high: PCF2123 needs chipselect high
>> -
>> -Example:
>> -
>> -pcf2123: rtc@3 {
>> - compatible = "nxp,pcf2123"
>> - reg = <3>
>> - spi-cs-high;
>> -};
>>
>> ---
>> base-commit: 535a265d7f0dd50d8c3a4f8b4f3a452d56bd160f
>> change-id: 20230907-topic-pcf2123_yaml-2ce57f4e77d7
>>
>> Best regards,
>> --
>> Javier Carrasco <javier.carrasco.cruz@gmail.com>
>>
>
Best regards,
Javier Carrasco
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] dt-bindings: rtc: pcf2123: convert to YAML
2023-09-10 11:00 [PATCH] dt-bindings: rtc: pcf2123: convert to YAML Javier Carrasco
2023-09-10 12:17 ` Alexandre Belloni
@ 2023-09-11 6:17 ` Krzysztof Kozlowski
2023-09-11 8:27 ` Javier Carrasco
1 sibling, 1 reply; 6+ messages in thread
From: Krzysztof Kozlowski @ 2023-09-11 6:17 UTC (permalink / raw)
To: Javier Carrasco, Alessandro Zummo, Alexandre Belloni, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Chris Verges
Cc: linux-rtc, devicetree, linux-kernel
On 10/09/2023 13:00, Javier Carrasco wrote:
> Convert the existing txt binding to the preferred YAML format.
>
> +unevaluatedProperties: false
> +
> +examples:
> + - |
> + spi {
> + #address-cells = <1>;
> + #size-cells = <0>;
> +
> + rtc@3 {
> + compatible = "nxp,pcf2123";
> + reg = <3>;
> + spi-cs-high;
Example should be complete, so preferably also with interrupts.
Anyway:
Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Best regards,
Krzysztof
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] dt-bindings: rtc: pcf2123: convert to YAML
2023-09-11 6:17 ` Krzysztof Kozlowski
@ 2023-09-11 8:27 ` Javier Carrasco
0 siblings, 0 replies; 6+ messages in thread
From: Javier Carrasco @ 2023-09-11 8:27 UTC (permalink / raw)
To: Krzysztof Kozlowski, Javier Carrasco, Alessandro Zummo,
Alexandre Belloni, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Chris Verges
Cc: linux-rtc, devicetree, linux-kernel
On 11.09.23 08:17, Krzysztof Kozlowski wrote:
> On 10/09/2023 13:00, Javier Carrasco wrote:
>> Convert the existing txt binding to the preferred YAML format.
>>
>
>> +unevaluatedProperties: false
>> +
>> +examples:
>> + - |
>> + spi {
>> + #address-cells = <1>;
>> + #size-cells = <0>;
>> +
>> + rtc@3 {
>> + compatible = "nxp,pcf2123";
>> + reg = <3>;
>> + spi-cs-high;
>
> Example should be complete, so preferably also with interrupts.
>
> Anyway:
>
> Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
>
> Best regards,
> Krzysztof
>
Thank you for the review. You are right, adding a line to complete the
example with an interrupt does not cost much. I will add it for v2 and
wait a few days in case I should change the maintainer.
Best regards,
Javier Carrasco
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] dt-bindings: rtc: pcf2123: convert to YAML
2023-09-10 12:17 ` Alexandre Belloni
2023-09-10 12:31 ` Javier Carrasco
@ 2023-09-11 8:43 ` Javier Carrasco
1 sibling, 0 replies; 6+ messages in thread
From: Javier Carrasco @ 2023-09-11 8:43 UTC (permalink / raw)
To: Alexandre Belloni
Cc: Alessandro Zummo, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Chris Verges, linux-rtc, devicetree, linux-kernel
On 10.09.23 14:17, Alexandre Belloni wrote:
> On 10/09/2023 13:00:27+0200, Javier Carrasco wrote:
>> Convert the existing txt binding to the preferred YAML format.
>>
>> The pcf2123 node may contain SPI settings such as spi-cs-high and
>> spi-max-frequency, which keeps it from being added to the trivial-rtc
>> binding with its current definition. Add a reference to
>> spi-peripheral-props.yaml to account for that.
>>
>> The "interrupts" property was missing in the binding although it is
>> already supported. Add the missing property in the new binding.
>>
>> Signed-off-by: Javier Carrasco <javier.carrasco.cruz@gmail.com>
>> ---
>> .../devicetree/bindings/rtc/nxp,pcf2123.yaml | 45 ++++++++++++++++++++++
>> .../devicetree/bindings/rtc/nxp,rtc-2123.txt | 17 --------
>> 2 files changed, 45 insertions(+), 17 deletions(-)
>>
>> diff --git a/Documentation/devicetree/bindings/rtc/nxp,pcf2123.yaml b/Documentation/devicetree/bindings/rtc/nxp,pcf2123.yaml
>> new file mode 100644
>> index 000000000000..013e5e5dc0ae
>> --- /dev/null
>> +++ b/Documentation/devicetree/bindings/rtc/nxp,pcf2123.yaml
>> @@ -0,0 +1,45 @@
>> +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
>> +%YAML 1.2
>> +---
>> +$id: http://devicetree.org/schemas/rtc/nxp,pcf2123.yaml#
>> +$schema: http://devicetree.org/meta-schemas/core.yaml#
>> +
>> +title: NXP PCF2123 SPI Real Time Clock
>> +
>> +maintainers:
>> + - Chris Verges <chrisv@cyberswitching.com>
>
> Is Chris willing to maintain the binding?
>
The email address chrisv@cyberswitching.com does not exist anymore so it
is likely that Chris will not reply unless he is subscribed to the
mailing list with a different email address. I would propose that I add
myself as the binding maintainer and send a v2.
>> +
>> +allOf:
>> + - $ref: /schemas/spi/spi-peripheral-props.yaml#
>> + - $ref: rtc.yaml#
>> +
>> +properties:
>> + compatible:
>> + enum:
>> + - nxp,pcf2123
>> +
>> + reg:
>> + maxItems: 1
>> +
>> + interrupts:
>> + maxItems: 1
>> +
>> +required:
>> + - compatible
>> + - reg
>> +
>> +unevaluatedProperties: false
>> +
>> +examples:
>> + - |
>> + spi {
>> + #address-cells = <1>;
>> + #size-cells = <0>;
>> +
>> + rtc@3 {
>> + compatible = "nxp,pcf2123";
>> + reg = <3>;
>> + spi-cs-high;
>> + };
>> + };
>> +...
>> diff --git a/Documentation/devicetree/bindings/rtc/nxp,rtc-2123.txt b/Documentation/devicetree/bindings/rtc/nxp,rtc-2123.txt
>> deleted file mode 100644
>> index 7371f525a687..000000000000
>> --- a/Documentation/devicetree/bindings/rtc/nxp,rtc-2123.txt
>> +++ /dev/null
>> @@ -1,17 +0,0 @@
>> -NXP PCF2123 SPI Real Time Clock
>> -
>> -Required properties:
>> -- compatible: should be: "nxp,pcf2123"
>> - or "microcrystal,rv2123"
>> -- reg: should be the SPI slave chipselect address
>> -
>> -Optional properties:
>> -- spi-cs-high: PCF2123 needs chipselect high
>> -
>> -Example:
>> -
>> -pcf2123: rtc@3 {
>> - compatible = "nxp,pcf2123"
>> - reg = <3>
>> - spi-cs-high;
>> -};
>>
>> ---
>> base-commit: 535a265d7f0dd50d8c3a4f8b4f3a452d56bd160f
>> change-id: 20230907-topic-pcf2123_yaml-2ce57f4e77d7
>>
>> Best regards,
>> --
>> Javier Carrasco <javier.carrasco.cruz@gmail.com>
>>
>
Best regards,
Javier Carrasco
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2023-09-11 20:50 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-09-10 11:00 [PATCH] dt-bindings: rtc: pcf2123: convert to YAML Javier Carrasco
2023-09-10 12:17 ` Alexandre Belloni
2023-09-10 12:31 ` Javier Carrasco
2023-09-11 8:43 ` Javier Carrasco
2023-09-11 6:17 ` Krzysztof Kozlowski
2023-09-11 8:27 ` Javier Carrasco
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).