From: Marek =?utf-8?Q?Marczykowski-G=C3=B3recki?= Subject: Re: [PATCH] libxl: do not start dom0 qemu for stubdomain when not needed Date: Fri, 28 Jul 2017 18:05:13 +0200 Message-ID: <20170728160513.GQ1095@mail-itl> References: <1501109065-8022-1-git-send-email-marmarek@invisiblethingslab.com> <20170728151750.5ksd6hpl7ij65phu@citrix.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============3830399078137205645==" Return-path: In-Reply-To: <20170728151750.5ksd6hpl7ij65phu@citrix.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xen.org Sender: "Xen-devel" To: Wei Liu Cc: Ian Jackson , xen-devel@lists.xen.org List-Id: xen-devel@lists.xenproject.org --===============3830399078137205645== Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="EX0xjane0yZDWZrd" Content-Disposition: inline --EX0xjane0yZDWZrd Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Jul 28, 2017 at 04:17:51PM +0100, Wei Liu wrote: > On Thu, Jul 27, 2017 at 12:44:25AM +0200, Marek Marczykowski-G=C3=B3recki= wrote: > > diff --git a/tools/libxl/libxl_dm.c b/tools/libxl/libxl_dm.c > > index 44ebd70..c9aefe15 100644 > > --- a/tools/libxl/libxl_dm.c > > +++ b/tools/libxl/libxl_dm.c > > @@ -1868,13 +1868,17 @@ void libxl__spawn_stub_dm(libxl__egc *egc, libx= l__stub_dm_spawn_state *sdss) > > ret =3D libxl__domain_build_info_setdefault(gc, &dm_config->b_info= ); > > if (ret) goto out; > > =20 > > - GCNEW(vfb); > > - GCNEW(vkb); > > - libxl__vfb_and_vkb_from_hvm_guest_config(gc, guest_config, vfb, vk= b); > > - dm_config->vfbs =3D vfb; > > - dm_config->num_vfbs =3D 1; > > - dm_config->vkbs =3D vkb; > > - dm_config->num_vkbs =3D 1; > > + if (libxl_defbool_val(guest_config->b_info.u.hvm.vnc.enable) || > > + libxl_defbool_val(guest_config->b_info.u.hvm.spice.enable)= || > > + libxl_defbool_val(guest_config->b_info.u.hvm.sdl.enable)) { >=20 > Indentation. Should it really be indented at the same level as the code inside this block? Looks misleading (you need to look for ") {" to see where condition ends). > > + GCNEW(vfb); > > + GCNEW(vkb); > > + libxl__vfb_and_vkb_from_hvm_guest_config(gc, guest_config, vfb= , vkb); > > + dm_config->vfbs =3D vfb; > > + dm_config->num_vfbs =3D 1; > > + dm_config->vkbs =3D vkb; > > + dm_config->num_vkbs =3D 1; > > + } --=20 Best Regards, Marek Marczykowski-G=C3=B3recki Invisible Things Lab A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing? --EX0xjane0yZDWZrd Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQEcBAEBCAAGBQJZe2C6AAoJENuP0xzK19cssCkH/R4Ffw3nbiA7Vf+vEJY78Tc4 lZLuh+lICVI/OYs1ihyIVgDr2nwbowSj6R4XmRhdNX2uB/8t/lX+Dr3AvErQCoT2 JPH8asmsuh7Gf0PxaDL1V/vmxa/4nOTyzcgIcBVv22FYcLJR+1pjRru4noBCcHAJ PZA60wTU51yCZkc+NKaFvbBjHG/xSG2A5trYsIeEwuvBjBnn/CfmyX+q0OWitdcO hekx4YtcFdCs6brGHdYML5jiNYQFZwKTXQJfM9zwpsYy44X1C2FPNy1MkiYtMhsu pyW+sG/uzQk71A8H5tLc4nEqWXnS1qBRroz/1QeLRlCXFdzPpIQ5w8vhAcouEpQ= =d6mg -----END PGP SIGNATURE----- --EX0xjane0yZDWZrd-- --===============3830399078137205645== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX18KWGVuLWRldmVs IG1haWxpbmcgbGlzdApYZW4tZGV2ZWxAbGlzdHMueGVuLm9yZwpodHRwczovL2xpc3RzLnhlbi5v cmcveGVuLWRldmVsCg== --===============3830399078137205645==--