From mboxrd@z Thu Jan 1 00:00:00 1970 From: Dario Faggioli Subject: Re: Test result of xen-unstable changeset 25249 Date: Fri, 27 Apr 2012 17:20:25 +0200 Message-ID: <1335540025.2488.67.camel@Abyss> References: <1335435995180-5667212.post@n5.nabble.com> <1335441317.28015.127.camel@zakaz.uk.xensource.com> <20120427082114.GA28258@bloms.de> <4F9A5C79.2090604@eu.citrix.com> <1335517688.28015.180.camel@zakaz.uk.xensource.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============5560424805605324617==" Return-path: In-Reply-To: <1335517688.28015.180.camel@zakaz.uk.xensource.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: Ian Campbell Cc: George Dunlap , "xen-devel@lists.xensource.com" , Ian Jackson , Dieter Bloms , Fantu List-Id: xen-devel@lists.xenproject.org --===============5560424805605324617== Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="=-Dc7ahrhV1dd2nZH7i1al" --=-Dc7ahrhV1dd2nZH7i1al Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Fri, 2012-04-27 at 10:08 +0100, Ian Campbell wrote:=20 > > I think what we really want to do is is any of the parameters are set,= =20 > > after the domain is first created, to read the scheduling parameters fo= r=20 > > the domain (which will be the defaults), change the ones that are set i= n=20 > > the config file, and then write the whole structure back. That=20 > > shouldn't be too hard, as libxl__sched_set_params() is called after the= =20 > > domain itself is created; >=20 > I guess the low level libxl_sched_*_params_set should take care of this? >=20 Possibly, but there's more I'm not sure I understand in the patch (the original patch, the one that has been checked-in on Wednesday): +int libxl__sched_set_params(libxl__gc *gc, uint32_t domid, libxl_sched_par= ams *scparams) +{ + libxl_ctx *ctx =3D libxl__gc_owner(gc); + libxl_scheduler sched; + libxl_sched_sedf_domain sedf_info; + libxl_sched_credit_domain credit_info; + libxl_sched_credit2_domain credit2_info; + int ret; + + sched =3D libxl_get_scheduler (ctx); + switch (sched) { + case LIBXL_SCHEDULER_SEDF: + sedf_info.period =3D scparams->period; + sedf_info.slice =3D scparams->slice; + sedf_info.latency =3D scparams->latency; + sedf_info.extratime =3D scparams->extratime; + sedf_info.weight =3D scparams->weight; + ret=3Dlibxl_sched_sedf_domain_set(ctx, domid, &sedf_info); + break; + case LIBXL_SCHEDULER_CREDIT: + credit_info.weight =3D scparams->weight; sched gets the return value of libxl_get_scheduler() which, if I'm not wrong , read the "default" xen scheduler for this boot, i.e., the one specified by the "sched=3D" boot command line or whatever the default for that is (credit1). After that it decides what libxl_sched_*_domain_set() to call basing right on that value. What I'm missing is what prevents the domain in question to be part of a cpupool (e.g., by specifying "poolid=3D" in its config file as well) for which the scheduler is a different one. It seems to me that, in such case, we will be setting the wrong set of parameters anyway, independently on how well we manage in putting a default in place for them... Am I missing something? If not, as I haven't found any way of finding out what scheduler is actually being used for a specific domain, shouldn't we add or mimic that (going through cpupool, perhaps, I haven't checked yet)? Thanks and Regards, Dario --=20 <> (Raistlin Majere) ----------------------------------------------------------------- Dario Faggioli, Ph.D, http://retis.sssup.it/people/faggioli Senior Software Engineer, Citrix Systems R&D Ltd., Cambridge (UK) --=-Dc7ahrhV1dd2nZH7i1al Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part Content-Transfer-Encoding: 7bit -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.12 (GNU/Linux) iEYEABECAAYFAk+auTkACgkQk4XaBE3IOsRB1gCfZgywyW7lgdlSMHxrDlMrmR85 b4gAoJ/5Q3nOeIPj6QG8rMlmgm7HU/5K =MRWO -----END PGP SIGNATURE----- --=-Dc7ahrhV1dd2nZH7i1al-- --===============5560424805605324617== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Xen-devel mailing list Xen-devel@lists.xen.org http://lists.xen.org/xen-devel --===============5560424805605324617==--