qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Ian Campbell <Ian.Campbell@citrix.com>
To: Julien Grall <julien.grall@citrix.com>
Cc: "xen-devel@lists.xensource.com" <xen-devel@lists.xensource.com>,
	"qemu-devel@nongnu.org" <qemu-devel@nongnu.org>,
	Stefano Stabellini <Stefano.Stabellini@eu.citrix.com>,
	Julian Pidancet <julian.pidancet@citrix.com>
Subject: Re: [Qemu-devel] [Xen-devel] Qemu disaggregation in Xen environment
Date: Mon, 5 Mar 2012 14:06:15 -0800	[thread overview]
Message-ID: <1330985175.22559.60.camel@cthulhu.hellion.org.uk> (raw)
In-Reply-To: <4F4CBE85.5000006@citrix.com>

On Tue, 2012-02-28 at 06:46 -0500, Julien Grall wrote:
> Hello,
> 
> In the current model, only one instance of qemu is running for each running HVM domain.
> 
> We are looking at disaggregating qemu to have, for example, an instance to emulate only
> network controllers, another to emulate block devices, etc...
> 
> Multiple instances of qemu would run for a single Xen domain. Each one would handle
> a subset of the hardware.
> 
> Has someone already looked at it and potentially already submitted code for qemu ?

I'm not aware of any code existing to do this.

There's a bunch of interesting stuff to do on the Xen side to make this
stuff work.

Firstly you would need to add support to the hypervisor for dispatching
I/O requests to multiple qemu instances (via multiple io req rings). I
think at the moment there is only support for a single ring (or maybe
it's one sync and one buffered I/O ring).

You'd also need to make sure that qemu explicitly requests all the MMIO
regions it is interested in. Currently the hypervisor forwards any
unknown MMIO to qemu so the explicit registration is probably not done
as consistently as it could be. If you want to have N qemus then you
need to make sure that at least N-1 of register for everything they are
interested in.

Currently the PCI config space decode is done within qemu which is a bit
tricky if you are wanting to have different emulated PCI devices in
different qemu processes. We think it would independently be an
architectural improvement to have the hypervisor do the PCI config space
decode anyway. This would allow it to forward the I/O to the correct
qemu (there are other benefits to this change, e.g. relating to PCI
passthrough and the handling of MSI configuration etc)

Then you'd need to do a bunch of toolstack level work to start and
manage the multiple qemu processes instead of the existing single
process.

So, a bunch of stuff but I think it is all reasonable to do individually
and each brings its own advantages to the architecture outside of this
project too.

> The purpose of this e-mail is to start a discussion and gather opinions on how the
> qemu developers community would like to see it implemented.
> 
> A couple of questions comes to mind:

I guess these are mostly qemu side questions. I'm not familiar enough
with the internals on that side to answer really.

> 1) How hard would it be to untangle "machine" specific (PC hardware) emulation
> from "device" specific emulation (PCI devices) ?
> 
> 2) How can we achieve disaggregation from a configuration point of view. Currently,
> Xen toolstack starts qemu, and tells qemu which device to emulate using the command
> line. I've heard about a project for creating machine description configuration files
> for QEMU which could help greatly in dividing up which hardware to emulate in which
> instance of qemu.

I've only vaguely heard about this but it certainly seems like
functionality which would benefit more than just Xen.

Ian.

>  What is the status of this project ?
> 
> Thank you for your answers,
> 
> 
> _______________________________________________
> Xen-devel mailing list
> Xen-devel@lists.xen.org
> http://lists.xen.org/xen-devel

  reply	other threads:[~2012-03-05 22:06 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-02-28 11:46 [Qemu-devel] Qemu disaggregation in Xen environment Julien Grall
2012-03-05 22:06 ` Ian Campbell [this message]
2012-03-12 13:42   ` [Qemu-devel] [Xen-devel] " Julien Grall
2012-03-05 22:20 ` [Qemu-devel] " Anthony Liguori
2012-03-05 22:53   ` Stefano Stabellini
2012-03-06  1:45     ` Anthony Liguori
2012-03-06  8:22       ` Markus Armbruster
2012-03-06 15:11         ` Anthony Liguori
2012-03-12 13:17       ` Stefano Stabellini

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=1330985175.22559.60.camel@cthulhu.hellion.org.uk \
    --to=ian.campbell@citrix.com \
    --cc=Stefano.Stabellini@eu.citrix.com \
    --cc=julian.pidancet@citrix.com \
    --cc=julien.grall@citrix.com \
    --cc=qemu-devel@nongnu.org \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).