1# SPDX-License-Identifier: GPL-2.0 2%YAML 1.2 3--- 4$id: http://devicetree.org/schemas/rtc/allwinner,sun6i-a31-rtc.yaml# 5$schema: http://devicetree.org/meta-schemas/core.yaml# 6 7title: Allwinner A31 RTC Device Tree Bindings 8 9maintainers: 10 - Chen-Yu Tsai <wens@csie.org> 11 - Maxime Ripard <maxime.ripard@bootlin.com> 12 13properties: 14 "#clock-cells": 15 const: 1 16 17 compatible: 18 oneOf: 19 - const: allwinner,sun6i-a31-rtc 20 - const: allwinner,sun8i-a23-rtc 21 - const: allwinner,sun8i-h3-rtc 22 - items: 23 - const: allwinner,sun8i-r40-rtc 24 - const: allwinner,sun8i-h3-rtc 25 - const: allwinner,sun8i-v3-rtc 26 - const: allwinner,sun50i-h5-rtc 27 - items: 28 - const: allwinner,sun50i-a64-rtc 29 - const: allwinner,sun8i-h3-rtc 30 31 reg: 32 maxItems: 1 33 34 interrupts: 35 items: 36 - description: RTC Alarm 0 37 - description: RTC Alarm 1 38 39 clocks: 40 maxItems: 1 41 42 clock-output-names: 43 minItems: 1 44 maxItems: 3 45 description: 46 The RTC provides up to three clocks 47 - the Low Frequency Oscillator or LOSC, at index 0, 48 - the Low Frequency Oscillator External output (X32KFOUT in 49 the datasheet), at index 1, 50 - the Internal Oscillator, at index 2. 51 52allOf: 53 - $ref: "rtc.yaml#" 54 - if: 55 properties: 56 compatible: 57 contains: 58 const: allwinner,sun6i-a31-rtc 59 60 then: 61 properties: 62 clock-output-names: 63 minItems: 1 64 maxItems: 1 65 66 - if: 67 properties: 68 compatible: 69 contains: 70 enum: 71 - allwinner,sun8i-a23-rtc 72 - allwinner,sun8i-v3-rtc 73 74 then: 75 properties: 76 clock-output-names: 77 minItems: 2 78 maxItems: 2 79 80 - if: 81 properties: 82 compatible: 83 contains: 84 enum: 85 - allwinner,sun8i-h3-rtc 86 - allwinner,sun50i-h5-rtc 87 88 then: 89 properties: 90 clock-output-names: 91 minItems: 3 92 maxItems: 3 93 94required: 95 - "#clock-cells" 96 - compatible 97 - reg 98 - interrupts 99 - clocks 100 - clock-output-names 101 102additionalProperties: false 103 104examples: 105 - | 106 rtc: rtc@1f00000 { 107 compatible = "allwinner,sun6i-a31-rtc"; 108 reg = <0x01f00000 0x400>; 109 interrupts = <0 40 4>, <0 41 4>; 110 clock-output-names = "osc32k"; 111 clocks = <&ext_osc32k>; 112 #clock-cells = <1>; 113 }; 114 115... 116