# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
%YAML 1.2
---
$id: http://devicetree.org/schemas/rtc/phytium,rtc.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title: Phytium Real Time Clock

select:
  properties:
    compatible:
     contains:
        const: phytium,rtc
  required:
    - compatible

allOf:
  - $ref: rtc.yaml#

maintainers:
  - Chen Baozi <chenbaozi@phytium.com.cn>

properties:
  compatible:
    items:
      - const: phytium,rtc

  reg:
    maxItems: 1

  interrupts:
    maxItems: 1

  clocks:
    maxItems: 1

  start-year: true

required:
  - compatible
  - reg
  - interrupts
  - clocks

additionalProperties: false

examples:
  - |
    rtc@2800d0000 {
        compatible = "phytium,rtc";
        reg = <0x0 0x2800d000 0x0 0x1000>;
        interrupts = <GIC_SPI 4 IRQ_TYPE_LEVEL_HIGH>;
        clocks = <&sysclk_48mhz>;
    };
