All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Radim Krčmář" <rkrcmar@redhat.com>
To: Paolo Bonzini <pbonzini@redhat.com>
Cc: David Matlack <dmatlack@google.com>, kvm@vger.kernel.org
Subject: Re: [PATCH 1/2] kvm: nVMX: don't flush VMCS12 during VMXOFF or VCPU teardown
Date: Wed, 2 Aug 2017 22:37:56 +0200	[thread overview]
Message-ID: <20170802203755.GE32403@flask> (raw)
In-Reply-To: <b5269b8f-18b7-61d2-18fe-0f2b003b175c@redhat.com>

2017-08-02 10:18+0200, Paolo Bonzini:
> On 01/08/2017 23:00, David Matlack wrote:
> > According to the Intel SDM, software cannot rely on the current VMCS to be
> > coherent after a VMXOFF or shutdown. So this is a valid way to handle VMCS12
> > flushes.
> > 
> > 24.11.1 Software Use of Virtual-Machine Control Structures
> > ...
> >   If a logical processor leaves VMX operation, any VMCSs active on
> >   that logical processor may be corrupted (see below). To prevent
> >   such corruption of a VMCS that may be used either after a return
> >   to VMX operation or on another logical processor, software should
> >   execute VMCLEAR for that VMCS before executing the VMXOFF instruction
> >   or removing power from the processor (e.g., as part of a transition
> >   to the S3 and S4 power states).
> > ...
> > 
> > This fixes a "suspicious rcu_dereference_check() usage!" warning during
> > kvm_vm_release() because nested_release_vmcs12() calls
> > kvm_vcpu_write_guest_page() without holding kvm->srcu.
> > 
> > Signed-off-by: David Matlack <dmatlack@google.com>
> > ---
> > This patch applies on top of Paolo's "[PATCH] KVM: nVMX: do not pin the VMCS12".
> > (http://www.mail-archive.com/linux-kernel@vger.kernel.org/msg1455166.html)
> 
> Thanks, I think Radim should first apply the RCU-on-teardown patch
> (which I'll resend formally today), then "do not pin the VMCS12", then
> these two.
> 
> Reviewed-by: Paolo Bonzini <pbonzini@redhat.com>

Applied in that order, thanks.

      reply	other threads:[~2017-08-02 20:37 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-08-01 21:00 [PATCH 1/2] kvm: nVMX: don't flush VMCS12 during VMXOFF or VCPU teardown David Matlack
2017-08-01 21:00 ` [PATCH 2/2] KVM: nVMX: mark vmcs12 pages dirty on L2 exit David Matlack
2017-08-02  8:17   ` Paolo Bonzini
2017-08-02  8:18 ` [PATCH 1/2] kvm: nVMX: don't flush VMCS12 during VMXOFF or VCPU teardown Paolo Bonzini
2017-08-02 20:37   ` Radim Krčmář [this message]

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=20170802203755.GE32403@flask \
    --to=rkrcmar@redhat.com \
    --cc=dmatlack@google.com \
    --cc=kvm@vger.kernel.org \
    --cc=pbonzini@redhat.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.