From 5ded578a18c9515c2c0e1cd148ca42133bbcf055 Mon Sep 17 00:00:00 2001 From: Linus Walleij Date: Tue, 10 Oct 2023 21:42:11 +0200 Subject: rtc: rtc7301: Rewrite bindings in schema This rewrites the Epson RTC7301 bindings to use YAML schema, and adds a property for "reg-io-width" as used in several other bindings to account for different register strides. The USRobotics USR8200 uses the byte IO width. Reviewed-by: Rob Herring Signed-off-by: Linus Walleij Reviewed-by: Akinobu Mita Link: https://lore.kernel.org/r/20231010-rtc-7301-regwidth-v3-1-ade586b62794@linaro.org Signed-off-by: Alexandre Belloni --- .../devicetree/bindings/rtc/epson,rtc7301.txt | 16 ------- .../devicetree/bindings/rtc/epson,rtc7301.yaml | 51 ++++++++++++++++++++++ 2 files changed, 51 insertions(+), 16 deletions(-) delete mode 100644 Documentation/devicetree/bindings/rtc/epson,rtc7301.txt create mode 100644 Documentation/devicetree/bindings/rtc/epson,rtc7301.yaml (limited to 'Documentation') diff --git a/Documentation/devicetree/bindings/rtc/epson,rtc7301.txt b/Documentation/devicetree/bindings/rtc/epson,rtc7301.txt deleted file mode 100644 index 5f9df3f1467c..000000000000 --- a/Documentation/devicetree/bindings/rtc/epson,rtc7301.txt +++ /dev/null @@ -1,16 +0,0 @@ -EPSON TOYOCOM RTC-7301SF/DG - -Required properties: - -- compatible: Should be "epson,rtc7301sf" or "epson,rtc7301dg" -- reg: Specifies base physical address and size of the registers. -- interrupts: A single interrupt specifier. - -Example: - -rtc: rtc@44a00000 { - compatible = "epson,rtc7301dg"; - reg = <0x44a00000 0x10000>; - interrupt-parent = <&axi_intc_0>; - interrupts = <3 2>; -}; diff --git a/Documentation/devicetree/bindings/rtc/epson,rtc7301.yaml b/Documentation/devicetree/bindings/rtc/epson,rtc7301.yaml new file mode 100644 index 000000000000..bdb5cadb31cc --- /dev/null +++ b/Documentation/devicetree/bindings/rtc/epson,rtc7301.yaml @@ -0,0 +1,51 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/rtc/epson,rtc7301.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Epson Toyocom RTC-7301SF/DG + +description: + The only difference between the two variants is the packaging. + The DG variant is a DIL package, and the SF variant is a flat + package. + +maintainers: + - Akinobu Mita + +properties: + compatible: + enum: + - epson,rtc7301dg + - epson,rtc7301sf + + reg: + maxItems: 1 + + reg-io-width: + description: + The size (in bytes) of the IO accesses that should be performed + on the device. + enum: [1, 4] + default: 4 + + interrupts: + maxItems: 1 + +required: + - compatible + - reg + +additionalProperties: false + +examples: + - | + #include + rtc: rtc@44a00000 { + compatible = "epson,rtc7301dg"; + reg = <0x44a00000 0x10000>; + reg-io-width = <4>; + interrupt-parent = <&axi_intc_0>; + interrupts = <3 2>; + }; -- cgit v1.2.3 From fdaf4c5acf268bfcc455d8c2ab775cd54317c788 Mon Sep 17 00:00:00 2001 From: Javier Carrasco Date: Thu, 14 Sep 2023 11:07:59 +0200 Subject: dt-bindings: rtc: pcf2123: convert to YAML 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 Reviewed-by: Krzysztof Kozlowski Link: https://lore.kernel.org/r/20230907-topic-pcf2123_yaml-v2-1-ea87a8e12190@gmail.com Signed-off-by: Alexandre Belloni --- .../devicetree/bindings/rtc/nxp,pcf2123.yaml | 47 ++++++++++++++++++++++ .../devicetree/bindings/rtc/nxp,rtc-2123.txt | 17 -------- 2 files changed, 47 insertions(+), 17 deletions(-) create mode 100644 Documentation/devicetree/bindings/rtc/nxp,pcf2123.yaml delete mode 100644 Documentation/devicetree/bindings/rtc/nxp,rtc-2123.txt (limited to 'Documentation') diff --git a/Documentation/devicetree/bindings/rtc/nxp,pcf2123.yaml b/Documentation/devicetree/bindings/rtc/nxp,pcf2123.yaml new file mode 100644 index 000000000000..96e377a4d1bc --- /dev/null +++ b/Documentation/devicetree/bindings/rtc/nxp,pcf2123.yaml @@ -0,0 +1,47 @@ +# 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: + - Javier Carrasco + +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: + - | + #include + spi { + #address-cells = <1>; + #size-cells = <0>; + + rtc@3 { + compatible = "nxp,pcf2123"; + reg = <3>; + interrupts = ; + 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; -}; -- cgit v1.2.3 From 207bddd97881913bcb8bef84737c0971e712fbee Mon Sep 17 00:00:00 2001 From: Nikita Shubin Date: Fri, 15 Sep 2023 11:10:55 +0300 Subject: dt-bindings: rtc: Add Cirrus EP93xx Add device tree bindings for the Cirrus Logic EP93xx RTC block used in these SoCs. Signed-off-by: Nikita Shubin Reviewed-by: Krzysztof Kozlowski Link: https://lore.kernel.org/r/20230915-ep93xx-v4-13-a1d779dcec10@maquefel.me Signed-off-by: Alexandre Belloni --- .../devicetree/bindings/rtc/cirrus,ep9301-rtc.yaml | 42 ++++++++++++++++++++++ 1 file changed, 42 insertions(+) create mode 100644 Documentation/devicetree/bindings/rtc/cirrus,ep9301-rtc.yaml (limited to 'Documentation') diff --git a/Documentation/devicetree/bindings/rtc/cirrus,ep9301-rtc.yaml b/Documentation/devicetree/bindings/rtc/cirrus,ep9301-rtc.yaml new file mode 100644 index 000000000000..a95f6af2b1c0 --- /dev/null +++ b/Documentation/devicetree/bindings/rtc/cirrus,ep9301-rtc.yaml @@ -0,0 +1,42 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/rtc/cirrus,ep9301-rtc.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Cirrus EP93xx Real Time Clock controller + +maintainers: + - Hartley Sweeten + - Alexander Sverdlin + +allOf: + - $ref: rtc.yaml# + +properties: + compatible: + oneOf: + - const: cirrus,ep9301-rtc + - items: + - enum: + - cirrus,ep9302-rtc + - cirrus,ep9307-rtc + - cirrus,ep9312-rtc + - cirrus,ep9315-rtc + - const: cirrus,ep9301-rtc + + reg: + maxItems: 1 + +required: + - compatible + - reg + +unevaluatedProperties: false + +examples: + - | + rtc@80920000 { + compatible = "cirrus,ep9301-rtc"; + reg = <0x80920000 0x100>; + }; -- cgit v1.2.3 From cf3cce410adeee6fe4aa74a1b629135acce958d4 Mon Sep 17 00:00:00 2001 From: Javier Carrasco Date: Wed, 6 Sep 2023 15:34:06 +0200 Subject: dt-bindings: rtc: mcp795: move to trivial-rtc The current mcp795 bindings in text format do not support validation and are missing the optional interrupt property that is currently supported. Adding the missing property makes the bindings identical to the existing trivial-rtc bindings. Add maxim,mcp795 to the trivial-rtc bindings and delete current .txt bindings Signed-off-by: Javier Carrasco Reviewed-by: Krzysztof Kozlowski Link: https://lore.kernel.org/r/20230906-topic-rtc_mcp795_yaml-v3-1-5262f1b39920@gmail.com Signed-off-by: Alexandre Belloni --- Documentation/devicetree/bindings/rtc/maxim,mcp795.txt | 11 ----------- Documentation/devicetree/bindings/rtc/trivial-rtc.yaml | 2 ++ 2 files changed, 2 insertions(+), 11 deletions(-) delete mode 100644 Documentation/devicetree/bindings/rtc/maxim,mcp795.txt (limited to 'Documentation') diff --git a/Documentation/devicetree/bindings/rtc/maxim,mcp795.txt b/Documentation/devicetree/bindings/rtc/maxim,mcp795.txt deleted file mode 100644 index a59fdd8c236d..000000000000 --- a/Documentation/devicetree/bindings/rtc/maxim,mcp795.txt +++ /dev/null @@ -1,11 +0,0 @@ -* Maxim MCP795 SPI Serial Real-Time Clock - -Required properties: -- compatible: Should contain "maxim,mcp795". -- reg: SPI address for chip - -Example: - mcp795: rtc@0 { - compatible = "maxim,mcp795"; - reg = <0>; - }; diff --git a/Documentation/devicetree/bindings/rtc/trivial-rtc.yaml b/Documentation/devicetree/bindings/rtc/trivial-rtc.yaml index 2a65f31ac5a0..c9e3c5262c21 100644 --- a/Documentation/devicetree/bindings/rtc/trivial-rtc.yaml +++ b/Documentation/devicetree/bindings/rtc/trivial-rtc.yaml @@ -45,6 +45,8 @@ properties: - isil,isl1208 # Intersil ISL1218 Low Power RTC with Battery Backed SRAM - isil,isl1218 + # SPI-BUS INTERFACE REAL TIME CLOCK MODULE + - maxim,mcp795 # Real Time Clock Module with I2C-Bus - microcrystal,rv3029 # Real Time Clock -- cgit v1.2.3 From 539cbe1b81f44e13103795e41f2e000fdc170859 Mon Sep 17 00:00:00 2001 From: Fabio Estevam Date: Tue, 5 Sep 2023 19:08:26 -0300 Subject: dt-bindings: rtc: pcf8523: Convert to YAML Convert the PCF8523 bindings from text format to YAML. The YAML format is preferred as it allows validation. Signed-off-by: Fabio Estevam Reviewed-by: Sam Ravnborg Reviewed-by: Krzysztof Kozlowski Link: https://lore.kernel.org/r/20230905220826.79901-1-festevam@gmail.com Signed-off-by: Alexandre Belloni --- .../devicetree/bindings/rtc/nxp,pcf8523.txt | 18 --------- .../devicetree/bindings/rtc/nxp,pcf8523.yaml | 45 ++++++++++++++++++++++ 2 files changed, 45 insertions(+), 18 deletions(-) delete mode 100644 Documentation/devicetree/bindings/rtc/nxp,pcf8523.txt create mode 100644 Documentation/devicetree/bindings/rtc/nxp,pcf8523.yaml (limited to 'Documentation') diff --git a/Documentation/devicetree/bindings/rtc/nxp,pcf8523.txt b/Documentation/devicetree/bindings/rtc/nxp,pcf8523.txt deleted file mode 100644 index 0b1080c60f63..000000000000 --- a/Documentation/devicetree/bindings/rtc/nxp,pcf8523.txt +++ /dev/null @@ -1,18 +0,0 @@ -* NXP PCF8523 Real Time Clock - -Required properties: -- compatible: Should contain "nxp,pcf8523". -- reg: I2C address for chip. - -Optional property: -- quartz-load-femtofarads: The capacitive load of the quartz(x-tal), - expressed in femto Farad (fF). Valid values are 7000 and 12500. - Default value (if no value is specified) is 12500fF. - -Example: - -pcf8523: rtc@68 { - compatible = "nxp,pcf8523"; - reg = <0x68>; - quartz-load-femtofarads = <7000>; -}; diff --git a/Documentation/devicetree/bindings/rtc/nxp,pcf8523.yaml b/Documentation/devicetree/bindings/rtc/nxp,pcf8523.yaml new file mode 100644 index 000000000000..d11c8bc16bc0 --- /dev/null +++ b/Documentation/devicetree/bindings/rtc/nxp,pcf8523.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,pcf8523.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: NXP PCF8523 Real Time Clock + +maintainers: + - Sam Ravnborg + +allOf: + - $ref: rtc.yaml# + +properties: + compatible: + const: nxp,pcf8523 + + reg: + maxItems: 1 + + quartz-load-femtofarads: + description: + The capacitive load of the crystal, expressed in femto Farad (fF). + enum: [ 7000, 12500 ] + default: 12500 + +required: + - compatible + - reg + +unevaluatedProperties: false + +examples: + - | + i2c { + #address-cells = <1>; + #size-cells = <0>; + + rtc@68 { + compatible = "nxp,pcf8523"; + reg = <0x68>; + quartz-load-femtofarads = <7000>; + }; + }; -- cgit v1.2.3 From dc71c03b0a2937545d2c6ff89d2275890a309618 Mon Sep 17 00:00:00 2001 From: Marek Vasut Date: Thu, 21 Sep 2023 21:26:04 +0200 Subject: dt-bindings: rtc: microcrystal,rv3032: Document wakeup-source property The RV3032 can be used as a wake-up source, document the 'wakeup-source' property as allowed property. Signed-off-by: Marek Vasut Acked-by: Conor Dooley Link: https://lore.kernel.org/r/20230921192604.70944-1-marex@denx.de Signed-off-by: Alexandre Belloni --- Documentation/devicetree/bindings/rtc/microcrystal,rv3032.yaml | 2 ++ 1 file changed, 2 insertions(+) (limited to 'Documentation') diff --git a/Documentation/devicetree/bindings/rtc/microcrystal,rv3032.yaml b/Documentation/devicetree/bindings/rtc/microcrystal,rv3032.yaml index 27a9de10f0af..7680089d1d92 100644 --- a/Documentation/devicetree/bindings/rtc/microcrystal,rv3032.yaml +++ b/Documentation/devicetree/bindings/rtc/microcrystal,rv3032.yaml @@ -38,6 +38,8 @@ properties: - 3000 - 4400 + wakeup-source: true + required: - compatible - reg -- cgit v1.2.3 From cfb67623ce281e045ec11e3eddb1b68b879b53a1 Mon Sep 17 00:00:00 2001 From: Romain Perier Date: Wed, 13 Sep 2023 17:16:05 +0200 Subject: dt-bindings: rtc: Add Mstar SSD202D RTC Add YAML bindings for Mstar SSD202D RTC. Signed-off-by: Romain Perier Link: https://lore.kernel.org/r/20230913151606.69494-3-romain.perier@gmail.com Signed-off-by: Alexandre Belloni --- .../devicetree/bindings/rtc/mstar,ssd202d-rtc.yaml | 35 ++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 Documentation/devicetree/bindings/rtc/mstar,ssd202d-rtc.yaml (limited to 'Documentation') diff --git a/Documentation/devicetree/bindings/rtc/mstar,ssd202d-rtc.yaml b/Documentation/devicetree/bindings/rtc/mstar,ssd202d-rtc.yaml new file mode 100644 index 000000000000..4c1f22ef5a2c --- /dev/null +++ b/Documentation/devicetree/bindings/rtc/mstar,ssd202d-rtc.yaml @@ -0,0 +1,35 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/rtc/mstar,ssd202d-rtc.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Mstar SSD202D Real Time Clock + +maintainers: + - Daniel Palmer + - Romain Perier + +allOf: + - $ref: rtc.yaml# + +properties: + compatible: + enum: + - mstar,ssd202d-rtc + reg: + maxItems: 1 + +required: + - compatible + - reg + +unevaluatedProperties: false + +examples: + - | + rtc@6800 { + compatible = "mstar,ssd202d-rtc"; + reg = <0x6800 0x200>; + }; +... -- cgit v1.2.3