2024-04-10 16:23:31

by Javier Carrasco

[permalink] [raw]
Subject: [PATCH v2 0/4] rtc: convert multiple bindings into dtschema

This series converts the following bindings into dtschema, moving them
to trivial-rtc whenever possible:

- orion-rtc: trival-rtc, referenced in arm arch.
- google,goldfish-rtc: trivial-rtc, referenced in mips arch.
- lpc32xx-rtc: add missing property and convert, referenced in arm arch.
- maxim,ds1742: trivial-rtc, not referenced in arch, cheap conversion.
- rtc-aspeed: 3 devices to trivial-rtc, all referenced in arm arch.
- pxa-rtc: add missing properties and convert. Referenced in arm arch.
- st,spear600-rtc: trivial-rtc, referenced in arm arch.
- stmp3xxx-rtc: add compatibles and convert, referenced in arm arch.
- via,vt8500-rtc: trivial-rtc, referenced in arm arch.

Signed-off-by: Javier Carrasco <[email protected]>
---
Changes in v2:
- General: squash all moves to trivial-rtc into a single patch.
- MAINTAINERS: remove reference to google,goldfish-rtc.txt
- lpc32xx-rtc: create own binding to add the undocumented 'clocks'
property.
- fsl,stmp3xxx-rtc.yaml: document missing compatibles.
- Link to v1: https://lore.kernel.org/r/[email protected]

---
Javier Carrasco (4):
dt-bindings: rtc: convert trivial devices into dtschema
dt-bindings: rtc: lpc32xx-rtc: convert to dtschema
dt-bindings: rtc: pxa-rtc: convert to dtschema
dt-bindings: rtc: stmp3xxx-rtc: convert to dtschema

.../devicetree/bindings/rtc/fsl,stmp3xxx-rtc.yaml | 51 ++++++++++++++++++++++
.../bindings/rtc/google,goldfish-rtc.txt | 17 --------
.../devicetree/bindings/rtc/lpc32xx-rtc.txt | 15 -------
.../devicetree/bindings/rtc/marvell,pxa-rtc.yaml | 40 +++++++++++++++++
.../devicetree/bindings/rtc/maxim,ds1742.txt | 12 -----
.../devicetree/bindings/rtc/nxp,lpc32xx-rtc.yaml | 41 +++++++++++++++++
.../devicetree/bindings/rtc/orion-rtc.txt | 18 --------
Documentation/devicetree/bindings/rtc/pxa-rtc.txt | 14 ------
.../devicetree/bindings/rtc/rtc-aspeed.txt | 22 ----------
.../devicetree/bindings/rtc/spear-rtc.txt | 15 -------
.../devicetree/bindings/rtc/stmp3xxx-rtc.txt | 21 ---------
.../devicetree/bindings/rtc/trivial-rtc.yaml | 16 +++++++
.../devicetree/bindings/rtc/via,vt8500-rtc.txt | 15 -------
MAINTAINERS | 1 -
14 files changed, 148 insertions(+), 150 deletions(-)
---
base-commit: fec50db7033ea478773b159e0e2efb135270e3b7
change-id: 20240406-rtc_dtschema-302824d1ec20

Best regards,
--
Javier Carrasco <[email protected]>



2024-04-10 16:24:12

by Javier Carrasco

[permalink] [raw]
Subject: [PATCH v2 3/4] dt-bindings: rtc: pxa-rtc: convert to dtschema

Convert existing binding to dtschema to support validation.

The missing 'reg' and 'interrupts' properties have been added, taking
the 2 supported interrupts into account to fix the example.

Reviewed-by: Krzysztof Kozlowski <[email protected]>
Signed-off-by: Javier Carrasco <[email protected]>
---
.../devicetree/bindings/rtc/marvell,pxa-rtc.yaml | 40 ++++++++++++++++++++++
Documentation/devicetree/bindings/rtc/pxa-rtc.txt | 14 --------
2 files changed, 40 insertions(+), 14 deletions(-)

diff --git a/Documentation/devicetree/bindings/rtc/marvell,pxa-rtc.yaml b/Documentation/devicetree/bindings/rtc/marvell,pxa-rtc.yaml
new file mode 100644
index 000000000000..43d68681a1bf
--- /dev/null
+++ b/Documentation/devicetree/bindings/rtc/marvell,pxa-rtc.yaml
@@ -0,0 +1,40 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/rtc/marvell,pxa-rtc.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: PXA Real Time Clock
+
+maintainers:
+ - Javier Carrasco <[email protected]>
+
+allOf:
+ - $ref: rtc.yaml#
+
+properties:
+ compatible:
+ const: marvell,pxa-rtc
+
+ reg:
+ maxItems: 1
+
+ interrupts:
+ items:
+ - description: 1 Hz
+ - description: Alarm
+
+required:
+ - compatible
+ - reg
+ - interrupts
+
+unevaluatedProperties: false
+
+examples:
+ - |
+ rtc@40900000 {
+ compatible = "marvell,pxa-rtc";
+ reg = <0x40900000 0x3c>;
+ interrupts = <30>, <31>;
+ };
diff --git a/Documentation/devicetree/bindings/rtc/pxa-rtc.txt b/Documentation/devicetree/bindings/rtc/pxa-rtc.txt
deleted file mode 100644
index 8c6672a1b7d7..000000000000
--- a/Documentation/devicetree/bindings/rtc/pxa-rtc.txt
+++ /dev/null
@@ -1,14 +0,0 @@
-* PXA RTC
-
-PXA specific RTC driver.
-
-Required properties:
-- compatible : Should be "marvell,pxa-rtc"
-
-Examples:
-
-rtc@40900000 {
- compatible = "marvell,pxa-rtc";
- reg = <0x40900000 0x3c>;
- interrupts = <30 31>;
-};

--
2.40.1