]> git.ipfire.org Git - thirdparty/linux.git/commit
RISC-V: KVM: Don't check hstateen0 when updating sstateen0 CSR
authorAnup Patel <anup.patel@oss.qualcomm.com>
Tue, 20 Jan 2026 07:59:55 +0000 (13:29 +0530)
committerAnup Patel <anup@brainfault.org>
Fri, 3 Apr 2026 12:18:45 +0000 (17:48 +0530)
commite2494f83f9d717a7f607cfaefb4e69e55b8e024d
treebf2a654a14581d80230d99f73fde39e5cd6cb659
parent6ed523e2b6129d7dd4aab801a610930d85b2d3f8
RISC-V: KVM: Don't check hstateen0 when updating sstateen0 CSR

The hstateen0 will be programmed differently for guest HS-mode
and guest VS/VU-mode so don't check hstateen0.SSTATEEN0 bit when
updating sstateen0 CSR in kvm_riscv_vcpu_swap_in_guest_state()
and kvm_riscv_vcpu_swap_in_host_state().

Signed-off-by: Anup Patel <anup.patel@oss.qualcomm.com>
Reviewed-by: Radim Krčmář <radim.krcmar@oss.qualcomm.com>
Link: https://lore.kernel.org/r/20260120080013.2153519-10-anup.patel@oss.qualcomm.com
Signed-off-by: Anup Patel <anup@brainfault.org>
arch/riscv/kvm/vcpu.c