From mboxrd@z Thu Jan 1 00:00:00 1970 From: Wei Liu Subject: Re: [RFC 7/7] libxl: Wait for QEMU startup in stubdomain Date: Fri, 6 Feb 2015 11:16:16 +0000 Message-ID: <20150206111616.GD30821@zion.uk.xensource.com> References: <1423022775-7132-1-git-send-email-eshelton@pobox.com> <1423022775-7132-8-git-send-email-eshelton@pobox.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Content-Disposition: inline In-Reply-To: <1423022775-7132-8-git-send-email-eshelton@pobox.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Eric Shelton Cc: anthony.perard@citrix.com, xen-devel@lists.xensource.com, wei.liu2@citrix.com, Ian.Campbell@citrix.com, stefano.stabellini@eu.citrix.com List-Id: xen-devel@lists.xenproject.org Thanks for posting. On Tue, Feb 03, 2015 at 11:06:15PM -0500, Eric Shelton wrote: [...] > @@ -1368,12 +1401,24 @@ static void stubdom_pvqemu_cb(libxl__egc *egc, > libxl__stub_dm_spawn_state *sdss = CONTAINER_OF(multidev, *sdss, multidev); > STATE_AO_GC(sdss->dm.spawn.ao); > uint32_t dm_domid = sdss->pvqemu.guest_domid; > + libxl__xswait_state *xswait = &sdss->pvqemu.spawn.xswait; > > if (rc) { > LOGE(ERROR, "error connecting nics devices"); > goto out; > } > > + /* wait for PV stubdom QEMU instance to be ready */ > + libxl__xswait_init(xswait); > + xswait->ao = sdss->dm.spawn.ao; > + xswait->what = GCSPRINTF("stub domain %d startup", dm_domid); > + xswait->path = GCSPRINTF("/local/domain/0/device-model/%d/state", > + sdss->dm.guest_domid); FWIW we are now experiencing problem with this startup protocol (not Linux stubdom specific) -- that path that libxl waiting for is wrong. Unfortunately this problem can't be solved without putting in significant effort and time (involves redesign of protocol and handle all the compatibility issues). We can't say for sure when the solution is going to land. Also upstream QEMU stubdom, as you already notice, doesn't have a critical functionality -- save / restore. Adding that in might involve upstreaming some changes to QEMU, which has a time frame that is out of our control. So my hunch is that we're not going to make it in time for 4.6. :-/ Wei. > + xswait->timeout_ms = LIBXL_DEVICE_MODEL_START_TIMEOUT * 1000; > + xswait->callback = stub_dm_watch_event; > + rc = libxl__xswait_start(gc, xswait); > + if (rc) goto out; > + > rc = libxl_domain_unpause(CTX, dm_domid); > if (rc) goto out; > > @@ -1387,7 +1432,6 @@ static void stubdom_pvqemu_cb(libxl__egc *egc, > return; > } > } > - sdss->callback(egc, &sdss->dm, rc); > } > > static void spawn_stubdom_pvqemu_destroy_cb(libxl__egc *egc, > -- > 1.8.5.5 > > > _______________________________________________ > Xen-devel mailing list > Xen-devel@lists.xen.org > http://lists.xen.org/xen-devel