]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
Merge branch 'kvm-apx-prepare' into HEAD
authorPaolo Bonzini <pbonzini@redhat.com>
Wed, 13 May 2026 16:38:31 +0000 (12:38 -0400)
committerPaolo Bonzini <pbonzini@redhat.com>
Wed, 13 May 2026 16:38:31 +0000 (12:38 -0400)
Clean up KVM's register tracking and storage, primarily to prepare for
APX support, which expands the maximum number of GPRs from 16 to 32.

1  2 
arch/x86/include/asm/kvm_host.h
arch/x86/kvm/svm/svm.c
arch/x86/kvm/svm/svm.h
arch/x86/kvm/vmx/nested.c
arch/x86/kvm/vmx/tdx.c
arch/x86/kvm/vmx/vmx.c
arch/x86/kvm/vmx/vmx.h
arch/x86/kvm/x86.c

Simple merge
index 4519a1f925845396c644564b3e9cea814703d386,2b73d265015521c2fd0beefe12ede4c8ae0f81f1..b78dd8805ebb8c4e646753da82fa39ad768b3e74
@@@ -4576,9 -4554,9 +4576,9 @@@ static __no_kcsan fastpath_t svm_vcpu_r
                vcpu->arch.apf.host_apf_flags =
                        kvm_read_and_reset_apf_flags();
  
-       vcpu->arch.regs_avail &= ~SVM_REGS_LAZY_LOAD_SET;
+       kvm_clear_available_registers(vcpu, SVM_REGS_LAZY_LOAD_SET);
  
 -      if (!msr_write_intercepted(vcpu, MSR_AMD64_PERF_CNTR_GLOBAL_CTL))
 +      if (!msr_write_intercepted(svm, MSR_AMD64_PERF_CNTR_GLOBAL_CTL))
                rdmsrq(MSR_AMD64_PERF_CNTR_GLOBAL_CTL, vcpu_to_pmu(vcpu)->global_ctrl);
  
        trace_kvm_exit(vcpu, KVM_ISA_SVM);
Simple merge
Simple merge
Simple merge
index cc14a6b96681f55dcb148deb9d0bdcb2c2b094be,61eeafcd70f126236810f4bef2d71f54f64884d6..1701db1b2e1825760b443aadf50a2cea963468b8
@@@ -7485,10 -7468,11 +7485,10 @@@ static noinstr void vmx_vcpu_enter_exit
        if (vcpu->arch.cr2 != native_read_cr2())
                native_write_cr2(vcpu->arch.cr2);
  
 -      vmx->fail = __vmx_vcpu_run(vmx, (unsigned long *)&vcpu->arch.regs,
 -                                 flags);
 +      vmx->fail = __vmx_vcpu_run(vmx, flags);
  
        vcpu->arch.cr2 = native_read_cr2();
-       vcpu->arch.regs_avail &= ~VMX_REGS_LAZY_LOAD_SET;
+       kvm_clear_available_registers(vcpu, VMX_REGS_LAZY_LOAD_SET);
  
        vmx->idt_vectoring_info = 0;
  
Simple merge
Simple merge