[PATCH v6 1/8] riscv: do not read csr in vector context switch
Paul Walmsley
pjw at kernel.org
Tue Oct 6 03:01:51 PDT 2026
On Fri, 18 Sep 2026, Andy Chiu wrote:
> CSR operation can be costly as it may introduces serialization. Instead
> of reading from sstatus.vs to the detect voluntary context switch in
> kernel-mode vector, we can read the context depth from riscv_v_flags, as
> it is always non-zero on a trap-introduced context switch.
>
> Signed-off-by: Andy Chiu <tchiu at tenstorrent.com>
Thanks, queued for v7.4.
- Paul
More information about the linux-riscv
mailing list