1c3ac086fd
'enum' is equivalent to 'oneOf' with a list of 'const' entries, but 'enum' is more concise and yields better error messages. Cc: Maxime Ripard <mripard@kernel.org> Cc: Vignesh R <vigneshr@ti.com> Cc: Marc Zyngier <maz@kernel.org> Cc: Mauro Carvalho Chehab <mchehab@kernel.org> Cc: Lee Jones <lee.jones@linaro.org> Cc: "David S. Miller" <davem@davemloft.net> Cc: Jakub Kicinski <kuba@kernel.org> Cc: Bjorn Helgaas <bhelgaas@google.com> Cc: Kishon Vijay Abraham I <kishon@ti.com> Cc: Daniel Lezcano <daniel.lezcano@linaro.org> Cc: dmaengine@vger.kernel.org Cc: linux-i2c@vger.kernel.org Cc: linux-media@vger.kernel.org Cc: netdev@vger.kernel.org Cc: linux-pci@vger.kernel.org Cc: linux-phy@lists.infradead.org Cc: linux-serial@vger.kernel.org Cc: alsa-devel@alsa-project.org Cc: linux-spi@vger.kernel.org Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com> (mipi-ccs) Acked-by: Mark Brown <broonie@kernel.org> Reviewed-by: Vinod Koul <vkoul@kernel.org> Acked-By: Vinod Koul <vkoul@kernel.org> Acked-by: Wolfram Sang <wsa@kernel.org> # for I2C Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: Rob Herring <robh@kernel.org> Link: https://lore.kernel.org/r/20210824202014.978922-1-robh@kernel.org
98 lines
2.8 KiB
YAML
98 lines
2.8 KiB
YAML
# SPDX-License-Identifier: GPL-2.0
|
|
%YAML 1.2
|
|
---
|
|
$id: http://devicetree.org/schemas/timer/arm,sp804.yaml#
|
|
$schema: http://devicetree.org/meta-schemas/core.yaml#
|
|
|
|
title: ARM sp804 Dual Timers
|
|
|
|
maintainers:
|
|
- Haojian Zhuang <haojian.zhuang@linaro.org>
|
|
|
|
description: |+
|
|
The Arm SP804 IP implements two independent timers, configurable for
|
|
16 or 32 bit operation and capable of running in one-shot, periodic, or
|
|
free-running mode. The input clock is shared, but can be gated and prescaled
|
|
independently for each timer.
|
|
|
|
There is a viriant of Arm SP804: Hisilicon 64-bit SP804 timer. Some Hisilicon
|
|
SoCs, such as Hi1212, should use the dedicated compatible: "hisilicon,sp804".
|
|
|
|
# Need a custom select here or 'arm,primecell' will match on lots of nodes
|
|
select:
|
|
properties:
|
|
compatible:
|
|
contains:
|
|
enum:
|
|
- arm,sp804
|
|
- hisilicon,sp804
|
|
required:
|
|
- compatible
|
|
|
|
properties:
|
|
compatible:
|
|
items:
|
|
- enum:
|
|
- arm,sp804
|
|
- hisilicon,sp804
|
|
- const: arm,primecell
|
|
|
|
interrupts:
|
|
description: |
|
|
If two interrupts are listed, those are the interrupts for timer
|
|
1 and 2, respectively. If there is only a single interrupt, it is
|
|
either a combined interrupt or the sole interrupt of one timer, as
|
|
specified by the "arm,sp804-has-irq" property.
|
|
minItems: 1
|
|
maxItems: 2
|
|
|
|
reg:
|
|
description: The physical base address of the SP804 IP.
|
|
maxItems: 1
|
|
|
|
clocks:
|
|
description: |
|
|
Clocks driving the dual timer hardware. This list should
|
|
be 1 or 3 clocks. With 3 clocks, the order is timer0 clock, timer1
|
|
clock, apb_pclk. A single clock can also be specified if the same
|
|
clock is used for all clock inputs.
|
|
oneOf:
|
|
- items:
|
|
- description: clock for timer 1
|
|
- description: clock for timer 2
|
|
- description: bus clock
|
|
- items:
|
|
- description: unified clock for both timers and the bus
|
|
|
|
clock-names: true
|
|
# The original binding did not specify any clock names, and there is no
|
|
# consistent naming used in the existing DTs. The primecell binding
|
|
# requires the "apb_pclk" name, so we need this property.
|
|
# Use "timer0clk", "timer1clk", "apb_pclk" for new DTs.
|
|
|
|
arm,sp804-has-irq:
|
|
description: If only one interrupt line is connected to the interrupt
|
|
controller, this property specifies which timer is connected to this
|
|
line.
|
|
$ref: /schemas/types.yaml#/definitions/uint32
|
|
minimum: 1
|
|
maximum: 2
|
|
|
|
required:
|
|
- compatible
|
|
- interrupts
|
|
- reg
|
|
- clocks
|
|
|
|
additionalProperties: false
|
|
|
|
examples:
|
|
- |
|
|
timer0: timer@fc800000 {
|
|
compatible = "arm,sp804", "arm,primecell";
|
|
reg = <0xfc800000 0x1000>;
|
|
interrupts = <0 0 4>, <0 1 4>;
|
|
clocks = <&timclk1>, <&timclk2>, <&pclk>;
|
|
clock-names = "timer1", "timer2", "apb_pclk";
|
|
};
|