From: Yixun Lan <dlan@kernel.org>
To: Rob Herring <robh@kernel.org>,
Krzysztof Kozlowski <krzk+dt@kernel.org>,
Conor Dooley <conor+dt@kernel.org>,
Paul Walmsley <pjw@kernel.org>,
Palmer Dabbelt <palmer@dabbelt.com>,
Albert Ou <aou@eecs.berkeley.edu>,
Alexandre Ghiti <alex@ghiti.fr>
Cc: devicetree@vger.kernel.org, linux-riscv@lists.infradead.org,
spacemit@lists.linux.dev, linux-kernel@vger.kernel.org,
Yixun Lan <dlan@kernel.org>
Subject: [PATCH 1/4] riscv: dts: spacemit: k3: add clock tree
Date: Wed, 04 Mar 2026 07:36:42 +0000 [thread overview]
Message-ID: <20260304-01-dts-uart-full-v1-1-50a0aa53a245@kernel.org> (raw)
In-Reply-To: <20260304-01-dts-uart-full-v1-0-50a0aa53a245@kernel.org>
Add clock support to SpacemiT K3 SoC, the clock tree consist of several
blocks which are APBC, APMU, DCIU, MPUM.
Signed-off-by: Yixun Lan <dlan@kernel.org>
---
arch/riscv/boot/dts/spacemit/k3.dtsi | 75 ++++++++++++++++++++++++++++++++++++
1 file changed, 75 insertions(+)
diff --git a/arch/riscv/boot/dts/spacemit/k3.dtsi b/arch/riscv/boot/dts/spacemit/k3.dtsi
index b69cf81b5d55..e3d7f3102fd5 100644
--- a/arch/riscv/boot/dts/spacemit/k3.dtsi
+++ b/arch/riscv/boot/dts/spacemit/k3.dtsi
@@ -4,6 +4,7 @@
* Copyright (c) 2026 Guodong Xu <guodong@riscstar.com>
*/
+#include <dt-bindings/clock/spacemit,k3-clocks.h>
#include <dt-bindings/interrupt-controller/irq.h>
/dts-v1/;
@@ -398,6 +399,36 @@ core3 {
};
};
+ clocks {
+ vctcxo_1m: clock-1m {
+ compatible = "fixed-clock";
+ clock-frequency = <1000000>;
+ clock-output-names = "vctcxo_1m";
+ #clock-cells = <0>;
+ };
+
+ vctcxo_24m: clock-24m {
+ compatible = "fixed-clock";
+ clock-frequency = <24000000>;
+ clock-output-names = "vctcxo_24m";
+ #clock-cells = <0>;
+ };
+
+ vctcxo_3m: clock-3m {
+ compatible = "fixed-clock";
+ clock-frequency = <3000000>;
+ clock-output-names = "vctcxo_3m";
+ #clock-cells = <0>;
+ };
+
+ osc_32k: clock-32k {
+ compatible = "fixed-clock";
+ clock-frequency = <32000>;
+ clock-output-names = "osc_32k";
+ #clock-cells = <0>;
+ };
+ };
+
soc: soc {
compatible = "simple-bus";
interrupt-parent = <&saplic>;
@@ -406,6 +437,15 @@ soc: soc {
dma-noncoherent;
ranges;
+ syscon_apbc: system-controller@d4015000 {
+ compatible = "spacemit,k3-syscon-apbc";
+ reg = <0x0 0xd4015000 0x0 0x1000>;
+ clocks = <&osc_32k>, <&vctcxo_1m>, <&vctcxo_3m>, <&vctcxo_24m>;
+ clock-names = "osc", "vctcxo_1m", "vctcxo_3m", "vctcxo_24m";
+ #clock-cells = <1>;
+ #reset-cells = <1>;
+ };
+
uart0: serial@d4017000 {
compatible = "spacemit,k3-uart", "intel,xscale-uart";
reg = <0x0 0xd4017000 0x0 0x100>;
@@ -506,6 +546,41 @@ uart10: serial@d401f000 {
status = "disabled";
};
+ syscon_mpmu: system-controller@d4050000 {
+ compatible = "spacemit,k3-syscon-mpmu";
+ reg = <0x0 0xd4050000 0x0 0x10000>;
+ clocks = <&osc_32k>, <&vctcxo_1m>, <&vctcxo_3m>, <&vctcxo_24m>;
+ clock-names = "osc", "vctcxo_1m", "vctcxo_3m", "vctcxo_24m";
+ #clock-cells = <1>;
+ #power-domain-cells = <1>;
+ #reset-cells = <1>;
+ };
+
+ pll: clock-controller@d4090000 {
+ compatible = "spacemit,k3-pll";
+ reg = <0x0 0xd4090000 0x0 0x10000>;
+ clocks = <&vctcxo_24m>;
+ spacemit,mpmu = <&syscon_mpmu>;
+ #clock-cells = <1>;
+ };
+
+ syscon_apmu: system-controller@d4282800 {
+ compatible = "spacemit,k3-syscon-apmu";
+ reg = <0x0 0xd4282800 0x0 0x400>;
+ clocks = <&osc_32k>, <&vctcxo_1m>, <&vctcxo_3m>, <&vctcxo_24m>;
+ clock-names = "osc", "vctcxo_1m", "vctcxo_3m", "vctcxo_24m";
+ #clock-cells = <1>;
+ #power-domain-cells = <1>;
+ #reset-cells = <1>;
+ };
+
+ syscon_dciu: system-controller@d8440000 {
+ compatible = "spacemit,k3-syscon-dciu";
+ reg = <0x0 0xd8440000 0x0 0xc000>;
+ #clock-cells = <1>;
+ #reset-cells = <1>;
+ };
+
simsic: interrupt-controller@e0400000 {
compatible = "spacemit,k3-imsics", "riscv,imsics";
reg = <0x0 0xe0400000 0x0 0x200000>;
--
2.53.0
next prev parent reply other threads:[~2026-03-04 7:37 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-04 7:36 [PATCH 0/4] riscv: spacemit: k3: Add more resource to UART Yixun Lan
2026-03-04 7:36 ` Yixun Lan [this message]
2026-03-14 1:44 ` [PATCH 1/4] riscv: dts: spacemit: k3: add clock tree Samuel Holland
2026-03-14 8:52 ` Yixun Lan
2026-03-14 14:13 ` Samuel Holland
2026-03-20 10:03 ` Yixun Lan
2026-03-04 7:36 ` [PATCH 2/4] riscv: dts: spacemit: k3: add pinctrl support Yixun Lan
2026-03-04 7:36 ` [PATCH 3/4] riscv: dts: spacemit: k3: add GPIO support Yixun Lan
2026-03-04 7:36 ` [PATCH 4/4] riscv: dts: spacemit: k3: add full resource to UART Yixun Lan
2026-03-13 13:26 ` [PATCH 0/4] riscv: spacemit: k3: Add more " Yixun Lan
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260304-01-dts-uart-full-v1-1-50a0aa53a245@kernel.org \
--to=dlan@kernel.org \
--cc=alex@ghiti.fr \
--cc=aou@eecs.berkeley.edu \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=krzk+dt@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-riscv@lists.infradead.org \
--cc=palmer@dabbelt.com \
--cc=pjw@kernel.org \
--cc=robh@kernel.org \
--cc=spacemit@lists.linux.dev \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®