Skip to content

Commit 65bbf10

Browse files
ben717-linuxarndb
authored andcommitted
dt-bindings: timer: add Andes machine timer
Add the DT binding documentation for Andes machine timer. The RISC-V architecture defines a machine timer that provides a real-time counter and generates timer interrupts. Andes machiner timer (PLMT0) is the implementation of the machine timer, and it contains memory-mapped registers (mtime and mtimecmp). This device supports up to 32 cores. Acked-by: Conor Dooley <[email protected]> Signed-off-by: Ben Zong-You Xie <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Arnd Bergmann <[email protected]>
1 parent 1f5ff8c commit 65bbf10

File tree

1 file changed

+53
-0
lines changed

1 file changed

+53
-0
lines changed
Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2+
%YAML 1.2
3+
---
4+
$id: http://devicetree.org/schemas/timer/andestech,plmt0.yaml#
5+
$schema: http://devicetree.org/meta-schemas/core.yaml#
6+
7+
title: Andes machine-level timer
8+
9+
description:
10+
The Andes machine-level timer device (PLMT0) provides machine-level timer
11+
functionality for a set of HARTs on a RISC-V platform. It has a single
12+
fixed-frequency monotonic time counter (MTIME) register and a time compare
13+
register (MTIMECMP) for each HART connected to the PLMT0. A timer interrupt is
14+
generated if MTIME >= MTIMECMP.
15+
16+
maintainers:
17+
- Ben Zong-You Xie <[email protected]>
18+
19+
properties:
20+
compatible:
21+
items:
22+
- enum:
23+
- andestech,qilai-plmt
24+
- const: andestech,plmt0
25+
26+
reg:
27+
maxItems: 1
28+
29+
interrupts-extended:
30+
minItems: 1
31+
maxItems: 32
32+
description:
33+
Specifies which harts are connected to the PLMT0. Each item must points
34+
to a riscv,cpu-intc node, which has a riscv cpu node as parent. The
35+
PLMT0 supports 1 hart up to 32 harts.
36+
37+
additionalProperties: false
38+
39+
required:
40+
- compatible
41+
- reg
42+
- interrupts-extended
43+
44+
examples:
45+
- |
46+
interrupt-controller@100000 {
47+
compatible = "andestech,qilai-plmt", "andestech,plmt0";
48+
reg = <0x100000 0x100000>;
49+
interrupts-extended = <&cpu0intc 7>,
50+
<&cpu1intc 7>,
51+
<&cpu2intc 7>,
52+
<&cpu3intc 7>;
53+
};

0 commit comments

Comments
 (0)