[PATCH v3 0/4] LoongArch: KVM: Add FPU delay load support

Bibo Mao posted 4 patches 4 days, 4 hours ago
arch/loongarch/include/asm/kvm_host.h |  2 ++
arch/loongarch/kvm/exit.c             | 21 +++++++++---
arch/loongarch/kvm/vcpu.c             | 46 +++++++++++++++------------
3 files changed, 44 insertions(+), 25 deletions(-)
[PATCH v3 0/4] LoongArch: KVM: Add FPU delay load support
Posted by Bibo Mao 4 days, 4 hours ago
FPU is lazy enabled in KVM hypervisor. After FPU is enabled and loaded,
vCPU can be preempted and FPU will be lost, there will be FPU exception
and FPU load again.

Here FPU is delay load until guest enter entry.

---
v2 ... v3:
  1. Add LBT delay load support also.

v1 ... v2:
  1. Keep funtion trace_kvm_aux() with FPU restore called still, only
     remove preempt disable/enable API call.
  2. Use one KVM_REQ_FPU_LOAD request bit and add fpu_load_type int
     type, remove KVM_REQ_LSX_LOAD/KVM_REQ_LASX_LOAD request bit
---
Bibo Mao (4):
  LoongArch: KVM: Move LSX capability check in LSX exception handler
  LoongArch: KVM: Move LASX capability check in LASX exception handler
  LoongArch: KVM: Move LBT capability checking in LBT exception handler
  LoongArch: KVM: Add FPU delay load support

 arch/loongarch/include/asm/kvm_host.h |  2 ++
 arch/loongarch/kvm/exit.c             | 21 +++++++++---
 arch/loongarch/kvm/vcpu.c             | 46 +++++++++++++++------------
 3 files changed, 44 insertions(+), 25 deletions(-)


base-commit: dee65f79364c18033cabdf0728c7e7025405cf40
-- 
2.39.3