[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20221026035752.32681-2-zhuyinbo@loongson.cn>
Date: Wed, 26 Oct 2022 11:57:52 +0800
From: Yinbo Zhu <zhuyinbo@...ngson.cn>
To: Daniel Lezcano <daniel.lezcano@...aro.org>,
Thomas Gleixner <tglx@...utronix.de>,
Rob Herring <robh+dt@...nel.org>,
Krzysztof Kozlowski <krzysztof.kozlowski+dt@...aro.org>,
Huacai Chen <chenhuacai@...nel.org>,
WANG Xuerui <kernel@...0n.name>,
Jiaxun Yang <jiaxun.yang@...goat.com>,
Jianmin Lv <lvjianmin@...ngson.cn>,
Yun Liu <liuyun@...ngson.cn>,
Yang Li <yang.lee@...ux.alibaba.com>,
linux-kernel@...r.kernel.org, devicetree@...r.kernel.org,
loongarch@...ts.linux.dev, Yinbo Zhu <zhuyinbo@...ngson.cn>
Subject: [PATCH v4 2/2] dt-bindings: hpet: add loongson2 hpet
Add the loongson2 High Precision Event Timer (HPET) binding
with DT schema format using json-schema.
Signed-off-by: Yinbo Zhu <zhuyinbo@...ngson.cn>
---
Change in v4:
1. Fixup the clock-names that replace apb-clk with apb.
2. This patch need rely on clock patch, which patchwork
link was "https://patchwork.kernel.org/project/linux-clk/list/?series=688892".
.../bindings/timer/loongson,ls2k-hpet.yaml | 50 +++++++++++++++++++
MAINTAINERS | 1 +
2 files changed, 51 insertions(+)
create mode 100644 Documentation/devicetree/bindings/timer/loongson,ls2k-hpet.yaml
diff --git a/Documentation/devicetree/bindings/timer/loongson,ls2k-hpet.yaml b/Documentation/devicetree/bindings/timer/loongson,ls2k-hpet.yaml
new file mode 100644
index 000000000000..9682d86e3339
--- /dev/null
+++ b/Documentation/devicetree/bindings/timer/loongson,ls2k-hpet.yaml
@@ -0,0 +1,50 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/timer/loongson,ls2k-hpet.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Loongson2 High Precision Event Timer (HPET)
+
+maintainers:
+ - Yinbo Zhu <zhuyinbo@...ngson.cn>
+
+properties:
+ compatible:
+ const: loongson,ls2k-hpet
+
+ reg:
+ maxItems: 1
+
+ clocks:
+ items:
+ - description: SoC apb clock
+
+ clock-names:
+ items:
+ - const: apb
+
+ interrupts:
+ maxItems: 1
+
+required:
+ - compatible
+ - reg
+ - clocks
+ - clock-names
+ - interrupts
+
+additionalProperties: false
+
+examples:
+ - |
+ #include <dt-bindings/clock/loongson,ls2k-clk.h>
+ #include <dt-bindings/interrupt-controller/irq.h>
+ timer@...24000 {
+ compatible = "loongson,ls2k-hpet";
+ reg = <0x1fe24000 0x15f>;
+ clocks = <&clk LOONGSON2_APB_CLK>;
+ clock-names = "apb";
+ interrupt-parent = <&liointc0>;
+ interrupts = <21 IRQ_TYPE_LEVEL_LOW>;
+ };
diff --git a/MAINTAINERS b/MAINTAINERS
index db29c1dc2d89..8cc541ce89b8 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -11919,6 +11919,7 @@ LOONGSON2 SOC SERIES HPET DRIVER
M: Yinbo Zhu <zhuyinbo@...ngson.cn>
L: linux-kernel@...r.kernel.org
S: Maintained
+F: Documentation/devicetree/bindings/timer/loongson,ls2k-hpet.yaml
F: drivers/clocksource/loongson2_hpet.c
LSILOGIC MPT FUSION DRIVERS (FC/SAS/SPI)
--
2.31.1
Powered by blists - more mailing lists