All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jeremy Fitzhardinge <jeremy@goop.org>
To: "Nakajima, Jun" <jun.nakajima@intel.com>
Cc: "Yang, Sheng" <sheng.yang@intel.com>,
	"xen-devel@lists.xensource.com" <xen-devel@lists.xensource.com>,
	"Dong, Eddie" <eddie.dong@intel.com>,
	Keir Fraser <keir.fraser@eu.citrix.com>
Subject: Re: Xen: Hybrid extension patchset for hypervisor
Date: Wed, 16 Sep 2009 11:19:11 -0700	[thread overview]
Message-ID: <4AB12C1F.9080502@goop.org> (raw)
In-Reply-To: <0B53E02A2965CE4F9ADB38B34501A3A1940C78A8@orsmsx505.amr.corp.intel.com>

On 09/16/09 09:28, Nakajima, Jun wrote:
> Keir Fraser wrote on Wed, 16 Sep 2009 at 07:04:10:
>   
>>  By the way, if your intention is to speed up 64-bit guest performance,
>> then I think you should compare with running a full PV guest in a VMCS
>> container. That is runs in VMX non-root mode but still retains the usual
>> full-PV interfaces. I think that would be no more code than you are
>> proposing here, and would avoid scattering a bunch more code around the
>> guest OS, to which there is bound to be resistance.
>>     
> Do you mean running the existing 64-bit PV kernel binaries in a VMCS container?
>   

Yes.  I don't think there's any deep problem in doing that.

> Based on our data, what we would want in PV 64-bit guests are, fundamentally:
> - have the kernel run in ring 0 (so that it can regain the performance enhancements)
>   

That's no problem.  PV kernels don't currently assume they're running in
any particular ring, so they'd be happy to run in ring 0 if that's how
they're started (if there are problems, I'd consider that a bug).  We
could then check for ring 0 and enable syscall/sysenter.

> - use hardware-based MMU virtualization (e.g. EPT-based) if present
>   

We could do that with minimal API/ABI changes by:

    * Providing an identity p2m table
    * Changing the hypercall page to make pte writes simple memory
      writes (no hypercalls); xen would still keep track of pinned pages
      and trap'n'emulate on them for back-compatibility (but fast-path
      with no validation).  We could expose the presence of HAP via
      xen_features so that guests know they can avoid marking pagetables
      RO, etc.
    * Similarly, cr3 changes can be fast-pathed within the hypercall page.
    * Whatever else I've overlooked.

This would be very similar to how xenner gets PV guests running under kvm.

The tricky part might be in getting IO working, since it relies on
getting real MFNs for DMA.

At any rate, the changes need only be very localized within the
Xen-specific code.  I would not want to introduce a new or significantly
different kernel<->hypervisor ABI for any new modes (we have enough
already).

    J

  reply	other threads:[~2009-09-16 18:19 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-09-16  8:44 Xen: Hybrid extension patchset for hypervisor Yang, Sheng
2009-09-16  9:08 ` Keir Fraser
2009-09-16 14:04   ` Keir Fraser
2009-09-16 16:28     ` Nakajima, Jun
2009-09-16 18:19       ` Jeremy Fitzhardinge [this message]
2009-09-16 21:12         ` Ian Campbell
2009-09-16 21:22           ` Jeremy Fitzhardinge
2009-09-17  9:16             ` Ian Campbell
2009-09-17 15:56               ` Nakajima, Jun
2009-09-17 17:34                 ` Jeremy Fitzhardinge
2009-09-19  0:17                   ` Nakajima, Jun
2009-09-19  0:28                     ` Jeremy Fitzhardinge
2009-09-17 17:19               ` Jeremy Fitzhardinge
2009-09-16 19:11   ` Frank van der Linden
2009-09-17  6:13     ` Yang, Sheng
2009-09-17  6:25     ` Keir Fraser
2009-09-17  6:30       ` Sheng Yang
2009-09-17  6:47   ` Yang, Sheng

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=4AB12C1F.9080502@goop.org \
    --to=jeremy@goop.org \
    --cc=eddie.dong@intel.com \
    --cc=jun.nakajima@intel.com \
    --cc=keir.fraser@eu.citrix.com \
    --cc=sheng.yang@intel.com \
    --cc=xen-devel@lists.xensource.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.