public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
From: Marcelo Tosatti <mtosatti@redhat.com>
To: "Mao, Junjie" <junjie.mao@intel.com>
Cc: Eric Northup <digitaleric@google.com>,
	"kvm@vger.kernel.org" <kvm@vger.kernel.org>
Subject: Re: [PATCH] KVM: x86: Implement PCID/INVPCID for guests with EPT
Date: Tue, 15 May 2012 00:27:31 -0300	[thread overview]
Message-ID: <20120515032731.GC19552@amt.cnet> (raw)
In-Reply-To: <EF5A1D57CFBD5A4BA5EB3ED985B6DC6E067043@SHSMSX101.ccr.corp.intel.com>

On Tue, May 15, 2012 at 03:28:13AM +0000, Mao, Junjie wrote:
> > -----Original Message-----
> > From: Marcelo Tosatti [mailto:mtosatti@redhat.com]
> > Sent: Tuesday, May 15, 2012 10:20 AM
> > To: Mao, Junjie
> > Cc: Eric Northup; kvm@vger.kernel.org
> > Subject: Re: [PATCH] KVM: x86: Implement PCID/INVPCID for guests with EPT
> > 
> > On Mon, May 14, 2012 at 07:15:18AM +0000, Mao, Junjie wrote:
> > > > On Wed, May 9, 2012 at 5:32 PM, Mao, Junjie <junjie.mao@intel.com>
> > wrote:
> > > > > This patch handles PCID/INVPCID for guests.
> > > > >
> > > > > Process-context identifiers (PCIDs) are a facility by which a logical
> > processor may cache information for multiple linear-address spaces so that the
> > processor may retain cached information when software switches to a
> > different linear-address space. Refer to section 4.10.1 in IA32 Intel Software
> > Developer's Manual Volume 3A for details.
> > > > >
> > > > > For guests with EPT, the PCID feature is enabled and INVPCID behaves as
> > running natively.
> > > > > For guests without EPT, the PCID feature is disabled and INVPCID triggers
> > #UD.
> > > > >
> > > > Do I understand correctly that this means it is impossible to migrate a
> > guest which is using PCID from a host with EPT to a host without EPT (by
> > passing enable_ept=0 to the module, for example) ?
> > >
> > > I think you are right. Guests using PCID/INVPCID cannot migrate to a host
> > without it, and EPT is a precondition of this feature.
> > 
> > Are there processors that support PCI/INVPCID for the host but lack support
> > for SECONDARY_EXEC_ENABLE_INVPCID?
> 
> There're some with PCID but without INVPCID. For those processors support INVPCID, SECONDARY_EXEC_ENABLE_INVPCID support should be present. As PCID has little benefits without INVPCID, these two features are exposed/hidden as a whole.

That means migration control should check INVPCID host support before deciding
whether to migrate.

Thanks


      reply	other threads:[~2012-05-15  3:32 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-05-10  0:32 [PATCH] KVM: x86: Implement PCID/INVPCID for guests with EPT Mao, Junjie
2012-05-10 11:48 ` Avi Kivity
2012-05-11  5:58   ` Mao, Junjie
2012-05-13 10:02     ` Avi Kivity
2012-05-14  7:18       ` Mao, Junjie
2012-05-10 11:49 ` Avi Kivity
     [not found] ` <CAG7+5M2XSOoHqqpbp0YbjgNNfa6DwrfP+88TwRUbhBDUDH6q6A@mail.gmail.com>
2012-05-14  7:15   ` Mao, Junjie
2012-05-15  2:20     ` Marcelo Tosatti
2012-05-15  3:28       ` Mao, Junjie
2012-05-15  3:27         ` Marcelo Tosatti [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=20120515032731.GC19552@amt.cnet \
    --to=mtosatti@redhat.com \
    --cc=digitaleric@google.com \
    --cc=junjie.mao@intel.com \
    --cc=kvm@vger.kernel.org \
    /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