[PATCH v8 1/2] clocksource/drivers/timer-clint: Add ZICNTR support

Charlie Jenkins thecharlesjenkins at gmail.com
Sun Sep 20 22:16:37 PDT 2026


> ZICNTR allows the CPU time to be read using CSRs, which used to be the
> default. If ZICNTR is supported prefer using CSRs over MMIO.
> The clint MMIO is covered in the RISC-V ACLINT spec [1], which has
> not been ratified yet, where as the ZICNTR spec is ratified.

It's actually stronger than that, the ACLINT spec has been rejected:

https://riscv.atlassian.net/browse/RVS-3645
https://riscv.atlassian.net/browse/RVS-4913

> Using the CSRs also used to be the default, but was changed in
> Commit d5be89a8d118 ("RISC-V: Resurrect the MMIO timer implementation
> for M-mode systems") due to K210 not implementing rdtime in M-mode.
> 
> [1]: https://github.com/riscvarchive/riscv-aclint
> Signed-off-by: Jesse Taube <jtaubepe at redhat.com>
Reviewed-by: Charlie Jenkins <thecharlesjenkins at gmail.com>

-- 
- Charlie




More information about the linux-riscv mailing list