From: Junhui Liu <junhui.liu@pigmoral.tech>
To: Daniel Lezcano <daniel.lezcano@kernel.org>,
Thomas Gleixner <tglx@kernel.org>, Rob Herring <robh@kernel.org>,
Krzysztof Kozlowski <krzk+dt@kernel.org>,
Conor Dooley <conor+dt@kernel.org>, Yixun Lan <dlan@kernel.org>,
Inochi Amaoto <inochiama@outlook.com>,
Radu Rendec <radu@rendec.net>, Paul Walmsley <pjw@kernel.org>,
Samuel Holland <samuel.holland@sifive.com>,
Palmer Dabbelt <palmer@dabbelt.com>,
Anup Patel <anup@brainfault.org>,
Guodong Xu <docular.xu@gmail.com>,
Albert Ou <aou@eecs.berkeley.edu>,
Alexandre Ghiti <alex@ghiti.fr>
Cc: linux-kernel@vger.kernel.org, devicetree@vger.kernel.org,
linux-riscv@lists.infradead.org, spacemit@lists.linux.dev,
Conor Dooley <conor.dooley@microchip.com>,
Bo Gan <ganboing@gmail.com>,
Junhui Liu <junhui.liu@pigmoral.tech>
Subject: [PATCH v3 6/6] riscv: dts: spacemit: k3: Replace incorrect CLINT node with ACLINT nodes
Date: Fri, 18 Sep 2026 00:29:38 +0800 [thread overview]
Message-ID: <20260918-k3-aclint-v3-6-cf4fd4050e14@pigmoral.tech> (raw)
In-Reply-To: <20260918-k3-aclint-v3-0-cf4fd4050e14@pigmoral.tech>
The K3 implements separate ACLINT MSWI, MTIMER and SSWI devices. The
existing CLINT node at 0xe081c000 incorrectly describes the SSWI
register space in the non-secure window as a legacy CLINT.
The ACLINT register space is mapped at two base addresses: a secure
window at 0xf1810000 and a non-secure window at 0xe0810000. The
secure window exposes all three components, while the non-secure
window only exposes SSWI; the MSWI and MTIMER offsets are reserved
there. Moreover, depending on the eFuse configuration, the non-secure
window may be entirely inaccessible, whereas the secure window is
always available.
Replace the CLINT node with the three ACLINT devices, all using
secure-window addresses: MSWI and MTIMER for machine-level firmware
such as OpenSBI, and SSWI for supervisor software interrupts.
Fixes: 56f37e391a62 ("riscv: dts: spacemit: add initial support for K3 SoC")
Signed-off-by: Junhui Liu <junhui.liu@pigmoral.tech>
---
arch/riscv/boot/dts/spacemit/k3.dtsi | 43 +++++++++++++++++++++++++-----------
1 file changed, 30 insertions(+), 13 deletions(-)
diff --git a/arch/riscv/boot/dts/spacemit/k3.dtsi b/arch/riscv/boot/dts/spacemit/k3.dtsi
index c3f2dce0969c..74831974435e 100644
--- a/arch/riscv/boot/dts/spacemit/k3.dtsi
+++ b/arch/riscv/boot/dts/spacemit/k3.dtsi
@@ -1261,19 +1261,6 @@ saplic: interrupt-controller@e0804000 {
riscv,num-sources = <512>;
};
- clint: timer@e081c000 {
- compatible = "spacemit,k3-clint", "sifive,clint0";
- reg = <0x0 0xe081c000 0x0 0x4000>;
- interrupts-extended = <&cpu0_intc 3>, <&cpu0_intc 7>,
- <&cpu1_intc 3>, <&cpu1_intc 7>,
- <&cpu2_intc 3>, <&cpu2_intc 7>,
- <&cpu3_intc 3>, <&cpu3_intc 7>,
- <&cpu4_intc 3>, <&cpu4_intc 7>,
- <&cpu5_intc 3>, <&cpu5_intc 7>,
- <&cpu6_intc 3>, <&cpu6_intc 7>,
- <&cpu7_intc 3>, <&cpu7_intc 7>;
- };
-
/* sec_i2c3: 0xf0614000, not available from Linux */
mimsic: interrupt-controller@f1000000 {
@@ -1305,5 +1292,35 @@ maplic: interrupt-controller@f1800000 {
riscv,num-sources = <512>;
status = "reserved";
};
+
+ aclint_mswi: interrupt-controller@f1810000 {
+ compatible = "spacemit,k3-aclint-mswi";
+ reg = <0x0 0xf1810000 0x0 0x4000>;
+ interrupts-extended = <&cpu0_intc 3>, <&cpu1_intc 3>,
+ <&cpu2_intc 3>, <&cpu3_intc 3>,
+ <&cpu4_intc 3>, <&cpu5_intc 3>,
+ <&cpu6_intc 3>, <&cpu7_intc 3>;
+ };
+
+ aclint_mtimer: timer@f1814000 {
+ compatible = "spacemit,k3-aclint-mtimer";
+ reg = <0x0 0xf1814000 0x0 0x8000>;
+ reg-names = "mtimecmp";
+ interrupts-extended = <&cpu0_intc 7>, <&cpu1_intc 7>,
+ <&cpu2_intc 7>, <&cpu3_intc 7>,
+ <&cpu4_intc 7>, <&cpu5_intc 7>,
+ <&cpu6_intc 7>, <&cpu7_intc 7>;
+ };
+
+ aclint_sswi: interrupt-controller@f181c000 {
+ compatible = "spacemit,k3-aclint-sswi";
+ reg = <0x0 0xf181c000 0x0 0x4000>;
+ #interrupt-cells = <0>;
+ interrupt-controller;
+ interrupts-extended = <&cpu0_intc 1>, <&cpu1_intc 1>,
+ <&cpu2_intc 1>, <&cpu3_intc 1>,
+ <&cpu4_intc 1>, <&cpu5_intc 1>,
+ <&cpu6_intc 1>, <&cpu7_intc 1>;
+ };
};
};
--
2.55.0
next prev parent reply other threads:[~2026-09-17 16:31 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-17 16:29 [PATCH v3 0/6] spacemit: k3: Replace bad CLINT node with ACLINT nodes Junhui Liu
2026-09-17 16:29 ` [PATCH v3 1/6] dt-bindings: timer: thead,c900-aclint-mtimer: Add SpacemiT K3 Junhui Liu
2026-09-17 16:29 ` [PATCH v3 2/6] dt-bindings: interrupt-controller: thead,c900-aclint-mswi: " Junhui Liu
2026-09-17 16:29 ` [PATCH v3 3/6] dt-bindings: interrupt-controller: thead,c900-aclint-sswi: " Junhui Liu
2026-09-17 16:41 ` sashiko-bot
2026-09-17 16:29 ` [PATCH v3 4/6] dt-bindings: timer: sifive,clint: Remove spacemit,k3-clint Junhui Liu
2026-09-28 18:02 ` Rob Herring (Arm)
2026-09-17 16:29 ` [PATCH v3 5/6] irqchip/aclint-sswi: Add support for SpacemiT K3 Junhui Liu
2026-09-19 0:06 ` Yixun Lan
2026-10-02 11:25 ` Yixun Lan
2026-09-17 16:29 ` Junhui Liu [this message]
2026-09-18 23:52 ` [PATCH v3 0/6] spacemit: k3: Replace bad CLINT node with ACLINT nodes Yixun Lan
2026-10-02 11:19 ` 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=20260918-k3-aclint-v3-6-cf4fd4050e14@pigmoral.tech \
--to=junhui.liu@pigmoral.tech \
--cc=alex@ghiti.fr \
--cc=anup@brainfault.org \
--cc=aou@eecs.berkeley.edu \
--cc=conor+dt@kernel.org \
--cc=conor.dooley@microchip.com \
--cc=daniel.lezcano@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=dlan@kernel.org \
--cc=docular.xu@gmail.com \
--cc=ganboing@gmail.com \
--cc=inochiama@outlook.com \
--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=radu@rendec.net \
--cc=robh@kernel.org \
--cc=samuel.holland@sifive.com \
--cc=spacemit@lists.linux.dev \
--cc=tglx@kernel.org \
/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