summaryrefslogtreecommitdiff
path: root/lib/utils/timer
diff options
context:
space:
mode:
authorInochi Amaoto <[email protected]>2023-11-16 17:07:14 +0800
committerAnup Patel <[email protected]>2023-11-16 16:53:48 +0530
commitaccafb13d47ca1511364def6cd8840ef1f947e50 (patch)
tree4ef1996106c6dc41d7e6906a56c94f3b46b59765 /lib/utils/timer
parent896d2c99e239c8142be16cc6df979e7f805d8896 (diff)
lib: utils/timer: mtimer: add separate T-Head C9xx CLINT mtimer compatible
T-HEAD allows soc vendor to map the mtimer and mswi of C9xx clint on different address, which may cause a misuse if use the same compatible string, add a new timer compatible string to avoid this. Signed-off-by: Inochi Amaoto <[email protected]> Link: https://lore.kernel.org/linux-riscv/6e48cbe5e60f9ada2fd1fe58e803e127f1a678e5.1696433229.git.unicorn_wang@outlook.com/ Reviewed-by: Guo Ren <[email protected]> Reviewed-by: Anup Patel <[email protected]>
Diffstat (limited to 'lib/utils/timer')
-rw-r--r--lib/utils/timer/fdt_timer_mtimer.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/utils/timer/fdt_timer_mtimer.c b/lib/utils/timer/fdt_timer_mtimer.c
index 3d2dce02..3ba6b8f9 100644
--- a/lib/utils/timer/fdt_timer_mtimer.c
+++ b/lib/utils/timer/fdt_timer_mtimer.c
@@ -147,10 +147,16 @@ static const struct timer_mtimer_quirks thead_clint_quirks = {
.clint_without_mtime = true,
};
+static const struct timer_mtimer_quirks thead_aclint_quirks = {
+ .has_64bit_mmio = false,
+};
+
static const struct fdt_match timer_mtimer_match[] = {
{ .compatible = "riscv,clint0", .data = &sifive_clint_quirks },
{ .compatible = "sifive,clint0", .data = &sifive_clint_quirks },
{ .compatible = "thead,c900-clint", .data = &thead_clint_quirks },
+ { .compatible = "thead,c900-aclint-mtimer",
+ .data = &thead_aclint_quirks },
{ .compatible = "riscv,aclint-mtimer" },
{ },
};