All of lore.kernel.org
 help / color / mirror / Atom feed
From: Paul Durrant <Paul.Durrant@citrix.com>
To: Stefano Stabellini <Stefano.Stabellini@eu.citrix.com>
Cc: "qemu-devel@nongnu.org" <qemu-devel@nongnu.org>,
	Paolo Bonzini <pbonzini@redhat.com>,
	"xen-devel@lists.xen.org" <xen-devel@lists.xen.org>,
	Ian Campbell <Ian.Campbell@citrix.com>
Subject: Re: [Qemu-devel] [Xen-devel] [PATCH] Remove hardcoded xen-platform device initialization
Date: Thu, 20 Jun 2013 07:32:15 +0000	[thread overview]
Message-ID: <9AAE0902D5BC7E449B7C8E4E778ABCD004D3D8@LONPEX01CL01.citrite.net> (raw)
In-Reply-To: <alpine.DEB.2.02.1306191501320.4548@kaball.uk.xensource.com>

> -----Original Message-----
> From: Stefano Stabellini [mailto:stefano.stabellini@eu.citrix.com]
> Sent: 19 June 2013 17:28
> To: Paul Durrant
> Cc: Stefano Stabellini; Ian Campbell; Paolo Bonzini; xen-devel@lists.xen.org;
> qemu-devel@nongnu.org
> Subject: RE: [Qemu-devel] [Xen-devel] [PATCH] Remove hardcoded xen-
> platform device initialization
> 
> On Wed, 19 Jun 2013, Paul Durrant wrote:
> > > -----Original Message-----
> > > From: qemu-devel-bounces+paul.durrant=citrix.com@nongnu.org
> > > [mailto:qemu-devel-bounces+paul.durrant=citrix.com@nongnu.org] On
> > > Behalf Of Stefano Stabellini
> > > Sent: 19 June 2013 14:53
> > > To: Ian Campbell
> > > Cc: Paolo Bonzini; Paul Durrant; xen-devel@lists.xen.org; qemu-
> > > devel@nongnu.org; Stefano Stabellini
> > > Subject: Re: [Qemu-devel] [Xen-devel] [PATCH] Remove hardcoded xen-
> > > platform device initialization
> > >
> > > On Wed, 19 Jun 2013, Ian Campbell wrote:
> > > > On Tue, 2013-06-18 at 19:56 +0100, Stefano Stabellini wrote:
> > > > > On Fri, 14 Jun 2013, Paul Durrant wrote:
> > > > > > > -----Original Message-----
> > > > > > > From: Paolo Bonzini [mailto:paolo.bonzini@gmail.com] On Behalf
> Of
> > > Paolo
> > > > > > > Bonzini
> > > > > > > Sent: 14 June 2013 15:58
> > > > > > > To: Paul Durrant
> > > > > > > Cc: Ian Campbell; Stefano Stabellini; qemu-devel@nongnu.org;
> xen-
> > > > > > > devel@lists.xen.org
> > > > > > > Subject: Re: [Xen-devel] [PATCH] Remove hardcoded xen-
> platform
> > > device
> > > > > > > initialization
> > > > > > >
> > > > > > > Il 14/06/2013 10:11, Paul Durrant ha scritto:
> > > > > > > > I think we're still going to need -M xenpv, I think; it's quite
> > > > > > > > distinct from pc.
> > > > > > >
> > > > > > > Of course!  Even more: "-M xenpv" should be reused on ARM.
> > > > > > >
> > > > > > > > I guess we could use -M pc for HVM and gate the
> > > > > > > > accel code as you suggest but, if that's the way we're going, it
> > > > > > > > would seem more logical just to ditch the accel code for xenpv
> > > > > > > > completely (assuming we can do all we need from the machine
> init)
> > > and
> > > > > > > > then use -M pc -accel=xen for HVM guests going forward.
> > > > > > >
> > > > > > > There is common code between pv and fv, and that one definitely
> > > belongs
> > > > > > > in xen_init.  Most fv-only code probably should be in pc_init.  The
> rest
> > > > > > > should move to xen_init though, because it would apply just as
> well
> > > for
> > > > > > > example to Q35.  It's a bit ugly to have fv-only code there, but it's
> > > > > > > better than having a Xen-specific machine type.  Xen/KVM/TCG
> > > should be
> > > > > > > as similar as possible at the QEMU level, any difference should be
> > > > > > > handled in the toolstack.
> > > > > > >
> > > > > > > > But that does
> > > > > > > > rather screw up my autodiscovery plans because I would not
> know,
> > > for
> > > > > > > > a given qemu binary, which machine type to use.
> > > > > > >
> > > > > > > There's no need for that.  4.4 can just use "-M pc" unconditionally,
> > > > > > > <=4.3 will just use "-M xenfv" unconditionally.
> > > > > > >
> > > > > > > > If I create a new
> > > > > > > > xenfv-2.0 machine type though I *can* do auto discovery... in
> which
> > > > > > > > case do we need the -accel=xen option at all?
> > > > > > >
> > > > > > > Yes.  Please try not do things differently from other accelerators.
> > > > > > >
> > > > > >
> > > > > > Ok. I guess we can have the ability to override the machine type in
> the
> > > VM config, so you could still kick off an older qemu with a newer libxl -
> but it
> > > sounds like the auto-discovery idea is a no-go then.
> > > > >
> > > > > xenfv-2.0 is a bad idea, like Paolo wrote, it should be possible to just
> > > > > use -M pc for HVM guests and retain -M xenpv for pv guests.
> > > > >
> > > > > However it seems to me that we also need a way in libxl to find out
> > > > > whether QEMU is new enough for us to be able to use -M pc.
> > > > > We can't just assume that users will be able to figure out the magic
> > > > > rune they need to write in the VM config file to solve their VM crash
> at
> > > > > boot problem.
> > > >
> > > > What crash at boot problem?
> > >
> > > If you start QEMU as device model on Xen with the wrong machine
> option
> > > (for example -M pc on an old QEMU), QEMU would probably just abort
> > > during initialization.
> > >
> > >
> > > > > We could spawn an instance of QEMU just to figure out the QEMU
> > > version
> > > > > but we certainly cannot do that every time we start a new VM.
> > > > > Once we figure out the QEMU version the first time we could write it
> to
> > > > > xenstore so that the next time we don't have to go through the same
> > > > > process again.
> > > >
> > > > Due to the device_model_override we might need to make this per-
> path.
> > > > You'd also likely need to store mtime or something in case qemu gets
> > > > upgraded, although perhaps that is getting unnecessarily picky...
> > >
> > > I think of device_model_override as an option for developers. People
> > > that use device_model_override can also override the QEMUMachine
> > > version.
> >
> > Are you suggesting we allow a freeform -machine option in libxl, or are you
> suggesting they point device_model_override at a script which drops the -M
> argument and inserts their new choice before invoking qemu?
> 
> I am suggesting that we could have a qemu_machine_override option in
> QEMU, or maybe a device_models_args_override that not only adds any
> user
> supplied arguments to QEMU (like the current device_model_args) but also
> replace the default arguments completely.

But I intended the device_model_machine option exactly as such an override and you NACKed it. Was that because I limited the choice be using an enumeration rather than a freeform string?

  Paul

  reply	other threads:[~2013-06-20  7:32 UTC|newest]

Thread overview: 65+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-06-13  9:50 [Qemu-devel] [PATCH] Remove hardcoded xen-platform device initialization Paul Durrant
2013-06-13 17:33 ` Stefano Stabellini
2013-06-13 17:44   ` Ian Campbell
2013-06-13 17:44   ` [Qemu-devel] [Xen-devel] " Ian Campbell
2013-06-13 18:02     ` Paolo Bonzini
2013-06-13 18:02     ` [Qemu-devel] [Xen-devel] " Paolo Bonzini
2013-06-14  9:00       ` Paul Durrant
2013-06-14 10:38         ` [Qemu-devel] " Paul Durrant
2013-06-14 10:38         ` [Qemu-devel] [Xen-devel] " Paul Durrant
2013-06-14 13:50           ` Paolo Bonzini
2013-06-14 13:50           ` [Qemu-devel] [Xen-devel] " Paolo Bonzini
2013-06-14 14:11             ` Paul Durrant
2013-06-14 14:11             ` [Qemu-devel] [Xen-devel] " Paul Durrant
2013-06-14 14:57               ` Paolo Bonzini
2013-06-14 14:57               ` [Qemu-devel] [Xen-devel] " Paolo Bonzini
2013-06-14 15:10                 ` Paul Durrant
2013-06-14 15:10                 ` [Qemu-devel] [Xen-devel] " Paul Durrant
2013-06-18 18:56                   ` Stefano Stabellini
2013-06-18 18:56                   ` [Qemu-devel] [Xen-devel] " Stefano Stabellini
2013-06-18 19:12                     ` Paolo Bonzini
2013-06-18 19:12                     ` [Qemu-devel] [Xen-devel] " Paolo Bonzini
2013-06-18 19:35                       ` Stefano Stabellini
2013-06-18 21:38                         ` [Qemu-devel] " Andreas Färber
2013-06-18 21:38                         ` [Qemu-devel] [Xen-devel] " Andreas Färber
2013-06-19  8:29                           ` [Qemu-devel] " Ian Campbell
2013-06-19  8:29                           ` [Qemu-devel] [Xen-devel] " Ian Campbell
2013-06-19  8:37                             ` Paul Durrant
2013-06-19  8:37                             ` [Qemu-devel] " Paul Durrant
2013-06-19  8:41                             ` [Qemu-devel] [Xen-devel] " Paolo Bonzini
2013-06-19  8:56                               ` [Qemu-devel] " Ian Campbell
2013-06-19  8:56                               ` [Qemu-devel] [Xen-devel] " Ian Campbell
2013-06-19  9:11                                 ` Paul Durrant
2013-06-19  9:11                                 ` [Qemu-devel] " Paul Durrant
2013-06-19 12:51                                 ` Paolo Bonzini
2013-06-19 12:51                                 ` [Qemu-devel] [Xen-devel] " Paolo Bonzini
2013-06-19 13:47                                 ` [Qemu-devel] " Stefano Stabellini
2013-06-19 13:47                                 ` [Qemu-devel] [Xen-devel] " Stefano Stabellini
2013-06-19  8:41                             ` [Qemu-devel] " Paolo Bonzini
2013-06-19  8:27                         ` [Qemu-devel] [Xen-devel] " Paul Durrant
2013-06-19 13:55                           ` Stefano Stabellini
2013-06-19 13:55                           ` [Qemu-devel] [Xen-devel] " Stefano Stabellini
2013-06-19 15:09                             ` Ian Campbell
2013-06-19 15:09                             ` [Qemu-devel] [Xen-devel] " Ian Campbell
2013-06-19  8:27                         ` Paul Durrant
2013-06-18 19:35                       ` Stefano Stabellini
2013-06-19  8:11                     ` Ian Campbell
2013-06-19  8:11                     ` [Qemu-devel] [Xen-devel] " Ian Campbell
2013-06-19 13:53                       ` Stefano Stabellini
2013-06-19 14:00                         ` [Qemu-devel] " Paul Durrant
2013-06-19 14:00                         ` [Qemu-devel] [Xen-devel] " Paul Durrant
2013-06-19 16:27                           ` Stefano Stabellini
2013-06-20  7:32                             ` Paul Durrant [this message]
2013-06-20  7:32                             ` [Qemu-devel] " Paul Durrant
2013-06-19 16:27                           ` Stefano Stabellini
2013-06-19 13:53                       ` Stefano Stabellini
2013-06-14  9:00       ` Paul Durrant
2013-06-14  8:56     ` [Qemu-devel] [Xen-devel] " Paul Durrant
2013-06-14  8:56     ` [Qemu-devel] " Paul Durrant
2013-06-14  8:50   ` Paul Durrant
2013-06-14 13:52     ` Paolo Bonzini
2013-06-14 13:52     ` [Qemu-devel] " Paolo Bonzini
2013-06-14 13:57       ` Paul Durrant
2013-06-14 13:57       ` [Qemu-devel] " Paul Durrant
2013-06-14  8:50   ` Paul Durrant
2013-06-13 17:33 ` 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=9AAE0902D5BC7E449B7C8E4E778ABCD004D3D8@LONPEX01CL01.citrite.net \
    --to=paul.durrant@citrix.com \
    --cc=Ian.Campbell@citrix.com \
    --cc=Stefano.Stabellini@eu.citrix.com \
    --cc=pbonzini@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=xen-devel@lists.xen.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 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.