[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Xen-devel] [PATCH 1 of 3] Support of getting scheduler defaults
- To: Ian Campbell <Ian.Campbell@xxxxxxxxxx>
- From: Juergen Gross <juergen.gross@xxxxxxxxxxxxxx>
- Date: Wed, 23 May 2012 10:45:19 +0200
- Cc: George Dunlap <dunlapg@xxxxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxx>, Dario Faggioli <raistlin@xxxxxxxx>
- Delivery-date: Wed, 23 May 2012 08:45:53 +0000
- Domainkey-signature: s=s1536a; d=ts.fujitsu.com; c=nofws; q=dns; h=X-SBRSScore:X-IronPort-AV:Received:X-IronPort-AV: Received:Received:Message-ID:Date:From:Organization: User-Agent:MIME-Version:To:CC:Subject:References: In-Reply-To:Content-Type:Content-Transfer-Encoding; b=vfZwDCDNNpU3yiFIToyquZUreB3fTvyqZx8SjcexnJKKcn7qsTthbaKI Gu9dxAy1kiKdsuWNS2C16W56hKINNROlIdEj7+jpm8jH2oWKpb4ZIfGod RkAm0kWedXs6DBMFupAzcxL92MlKOviqIyKc3Plwy0bGT2rQoyPrK1x6f JBOlxtaSFDEHx0ZYjr+aCCXROEsmXhe1BaqD1m1qFkPjHnb2zJSUYwDxm 9muHH7oz6iCZwNAbiHrI41TozyPM7;
- List-id: Xen developer discussion <xen-devel.lists.xen.org>
On 05/23/2012 09:41 AM, Ian Campbell wrote:
# xl create vm1.cfg
Parsing config from vm1.cfg
libxl: error: libxl.c:3417:libxl_sched_sedf_domain_set: setting domain sched
sedf: Invalid argument
And I'm getting the above independently on what I put in the config file
(valid params, no params at all, etc.). I also can't change the
scheduling parameters of a domain on-line anymore:
# xl sched-sedf -d 3 -p 100 -s 50
libxl: error: libxl.c:3417:libxl_sched_sedf_domain_set: setting domain sched
sedf: Invalid argument
libxl_sched_sedf_domain_set failed.
I'll try digging a bit more into this ASAP.
It's easy: Ian repeated an error he (and I) corrected elsewhere:
He's always setting period, regardless of the changed parameter...
Not sure, I think Ian's patch fixes that:
I thought so to!
It fixes the original error.
--- a/tools/libxl/xl_cmdimpl.c Tue May 22 14:19:07 2012 +0100
+++ b/tools/libxl/xl_cmdimpl.c Tue May 22 15:58:47 2012 +0100
@@ -627,23 +627,20 @@ static void parse_config_data(const char
libxl_domain_build_info_init_type(b_info, c_info->type);
- /* the following is the actual config parsing with overriding values in
the structures */
+ /* the following is the actual config parsing with overriding
+ * values in the structures */
if (!xlu_cfg_get_long (config, "cpu_weight",&l, 0))
b_info->sched_params.weight = l;
if (!xlu_cfg_get_long (config, "cap",&l, 0))
b_info->sched_params.cap = l;
- if (!xlu_cfg_get_long (config, "tslice_ms",&l, 0))
- b_info->sched_params.tslice_ms = l;
- if (!xlu_cfg_get_long (config, "ratelimit_us",&l, 0))
- b_info->sched_params.ratelimit_us = l;
if (!xlu_cfg_get_long (config, "period",&l, 0))
b_info->sched_params.period = l;
if (!xlu_cfg_get_long (config, "slice",&l, 0))
- b_info->sched_params.period = l;
+ b_info->sched_params.slice = l;
if (!xlu_cfg_get_long (config, "latency",&l, 0))
- b_info->sched_params.period = l;
+ b_info->sched_params.latency = l;
if (!xlu_cfg_get_long (config, "extratime",&l, 0))
- b_info->sched_params.period = l;
+ b_info->sched_params.extratime = l;
So it has to be something else...
Oh yes:
+
+ if (scinfo->period != LIBXL_SCHED_DOMAIN_PARAM_PERIOD_DEFAULT)
+ period = scinfo->period * 1000000;
+ if (scinfo->slice != LIBXL_SCHED_DOMAIN_PARAM_SLICE_DEFAULT)
+ period = scinfo->slice * 1000000;
+ if (scinfo->latency != LIBXL_SCHED_DOMAIN_PARAM_LATENCY_DEFAULT)
+ period = scinfo->latency * 1000000;
+ if (scinfo->extratime != LIBXL_SCHED_DOMAIN_PARAM_EXTRATIME_DEFAULT)
+ period = scinfo->extratime;
+ if (scinfo->weight != LIBXL_SCHED_DOMAIN_PARAM_WEIGHT_DEFAULT)
+ period = scinfo->weight;
Regardless which parameter was changed, it is always 'period' which is set
to the changed value.
Juergen
--
Juergen Gross Principal Developer Operating Systems
PDG ES&S SWE OS6 Telephone: +49 (0) 89 3222 2967
Fujitsu Technology Solutions e-mail: juergen.gross@xxxxxxxxxxxxxx
Domagkstr. 28 Internet: ts.fujitsu.com
D-80807 Muenchen Company details: ts.fujitsu.com/imprint.html
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel
|