[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1db73488-4095-4ac1-ad10-139615981de2@redhat.com>
Date: Sat, 15 Feb 2025 01:08:00 +0100
From: Paolo Bonzini <pbonzini@...hat.com>
To: Sean Christopherson <seanjc@...gle.com>
Cc: kvm@...r.kernel.org, linux-kernel@...r.kernel.org,
John Stultz <jstultz@...gle.com>, Jim Mattson <jmattson@...gle.com>
Subject: Re: [PATCH] KVM: x86: Load DR6 with guest value only before entering
.vcpu_run() loop
On 2/15/25 01:06, Sean Christopherson wrote:
> On Fri, Feb 14, 2025, Paolo Bonzini wrote:
>> Queued, thanks.
>
> Drat, I was too slow today. I applied and pushed this to "kvm-x86 fixes" and
> linux-next (as of yesterday), along with a few other things, I just haven't sent
> out the "thanks" yet (got sidetracked).
>
> If you want to grab those, here's a semi-impromptu pull request. Otherwise I'll
> just drop this particular commit.
I had "KVM: nSVM: Enter guest mode before initializing nested NPT MMU"
on my list, but not the others.
I'll just pull these, thanks.
Paolo
> --
>
> The following changes since commit a64dcfb451e254085a7daee5fe51bf22959d52d3:
>
> Linux 6.14-rc2 (2025-02-09 12:45:03 -0800)
>
> are available in the Git repository at:
>
> https://github.com/kvm-x86/linux.git tags/kvm-x86-fixes-6.14-rcN
>
> for you to fetch changes up to c2fee09fc167c74a64adb08656cb993ea475197e:
>
> KVM: x86: Load DR6 with guest value only before entering .vcpu_run() loop (2025-02-12 08:59:38 -0800)
>
> ----------------------------------------------------------------
> KVM fixes for 6.14 part 1
>
> - Reject Hyper-V SEND_IPI hypercalls if the local APIC isn't being emulated
> by KVM to fix a NULL pointer dereference.
>
> - Enter guest mode (L2) from KVM's perspective before initializing the vCPU's
> nested NPT MMU so that the MMU is properly tagged for L2, not L1.
>
> - Load the guest's DR6 outside of the innermost .vcpu_run() loop, as the
> guest's value may be stale if a VM-Exit is handled in the fastpath.
>
> ----------------------------------------------------------------
> Sean Christopherson (6):
> KVM: x86: Reject Hyper-V's SEND_IPI hypercalls if local APIC isn't in-kernel
> KVM: selftests: Mark test_hv_cpuid_e2big() static in Hyper-V CPUID test
> KVM: selftests: Manage CPUID array in Hyper-V CPUID test's core helper
> KVM: selftests: Add CPUID tests for Hyper-V features that need in-kernel APIC
> KVM: nSVM: Enter guest mode before initializing nested NPT MMU
> KVM: x86: Load DR6 with guest value only before entering .vcpu_run() loop
>
> arch/x86/include/asm/kvm-x86-ops.h | 1 +
> arch/x86/include/asm/kvm_host.h | 1 +
> arch/x86/kvm/hyperv.c | 6 +++++-
> arch/x86/kvm/mmu/mmu.c | 2 +-
> arch/x86/kvm/svm/nested.c | 10 +++++-----
> arch/x86/kvm/svm/svm.c | 13 ++++++-------
> arch/x86/kvm/vmx/main.c | 1 +
> arch/x86/kvm/vmx/vmx.c | 10 ++++++----
> arch/x86/kvm/vmx/x86_ops.h | 1 +
> arch/x86/kvm/x86.c | 3 +++
> tools/testing/selftests/kvm/x86/hyperv_cpuid.c | 47 ++++++++++++++++++++++++++++++++---------------
> 11 files changed, 62 insertions(+), 33 deletions(-)
>
Powered by blists - more mailing lists