mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Paolo Bonzini <pbonzini@redhat.com>
To: Sean Christopherson <seanjc@google.com>
Cc: kvm@vger.kernel.org, linux-kernel@vger.kernel.org,
	John Stultz <jstultz@google.com>,
	Jim Mattson <jmattson@google.com>
Subject: Re: [PATCH] KVM: x86: Load DR6 with guest value only before entering .vcpu_run() loop
Date: Sat, 15 Feb 2025 01:08:00 +0100	[thread overview]
Message-ID: <1db73488-4095-4ac1-ad10-139615981de2@redhat.com> (raw)
In-Reply-To: <Z6_ai1HdLWiTJ2Pf@google.com>

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(-)
> 


  reply	other threads:[~2025-02-15  0:08 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-01-25  1:18 Sean Christopherson
2025-02-14 23:40 ` Paolo Bonzini
2025-02-15  0:06   ` Sean Christopherson
2025-02-15  0:08     ` Paolo Bonzini [this message]
2025-02-15  0:18       ` Sean Christopherson
2025-02-15  0:50 ` Sean Christopherson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1db73488-4095-4ac1-ad10-139615981de2@redhat.com \
    --to=pbonzini@redhat.com \
    --cc=jmattson@google.com \
    --cc=jstultz@google.com \
    --cc=kvm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=seanjc@google.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®