diff options
author | Vincent Chen <vincent.chen@sifive.com> | 2021-12-27 11:05:14 +0800 |
---|---|---|
committer | Anup Patel <anup@brainfault.org> | 2022-01-06 15:18:18 +0530 |
commit | 33e5b5746cc2336660c8710ba109d9a3923627b5 (patch) | |
tree | 57f04e4d5f58ce20973f94f7e1ea462235b98145 /LICENSES/preferred | |
parent | 3e06cdf10520e629e711b76b21070d6e67ae7d06 (diff) | |
download | linux-33e5b5746cc2336660c8710ba109d9a3923627b5.tar.bz2 |
KVM: RISC-V: Avoid spurious virtual interrupts after clearing hideleg CSR
When the last VM is terminated, the host kernel will invoke function
hardware_disable_nolock() on each CPU to disable the related virtualization
functions. Here, RISC-V currently only clears hideleg CSR and hedeleg CSR.
This behavior will cause the host kernel to receive spurious interrupts if
hvip CSR has pending interrupts and the corresponding enable bits in vsie
CSR are asserted. To avoid it, hvip CSR and vsie CSR must be cleared
before clearing hideleg CSR.
Fixes: 99cdc6c18c2d ("RISC-V: Add initial skeletal KVM support")
Signed-off-by: Vincent Chen <vincent.chen@sifive.com>
Reviewed-by: Anup Patel <anup.patel@wdc.com>
Signed-off-by: Anup Patel <anup.patel@wdc.com>
Diffstat (limited to 'LICENSES/preferred')
0 files changed, 0 insertions, 0 deletions