This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
Home Products Support Community News


Re: [Xen-devel][PATCH] xl create: endless loop

To: <xen-devel@xxxxxxxxxxxxxxxxxxx>, Ian Jackson <Ian.Jackson@xxxxxxxxxxxxx>
Subject: Re: [Xen-devel][PATCH] xl create: endless loop
From: Christoph Egger <Christoph.Egger@xxxxxxx>
Date: Tue, 19 Oct 2010 10:31:31 +0200
Delivery-date: Tue, 19 Oct 2010 01:32:53 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <201010181450.36050.Christoph.Egger@xxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <201010181450.36050.Christoph.Egger@xxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: KMail/1.9.10
On Monday 18 October 2010 14:50:35 Christoph Egger wrote:
> Hi!
> I cannot start a guest with 'xl create' due to an endless loop in libxl.c,
> function libxl__get_free_memory_slack():
> There is this code snippet:
> retry:
>     free_mem_slack_s = libxl__xs_read(gc, XBT_NULL, free_mem_slack_path);
>     if (!free_mem_slack_s) {
>         rc = libxl__fill_dom0_memory_info(gc, &target_memkb);
>         if (rc < 0)
>             return rc;
>         goto retry;
>     } else {
> libxl__xs_read() returns 0 and libxl__fill_dom0_memory_info() also returns
> 0. So there's a loop of retries.

Attached patch fixes the endless loop.

Signed-off-by: Christoph Egger <Christoph.Egger@xxxxxxx>

---to satisfy European Law for business letters:
Advanced Micro Devices GmbH
Einsteinring 24, 85609 Dornach b. Muenchen
Geschaeftsfuehrer: Alberto Bozzo, Andrew Bowd
Sitz: Dornach, Gemeinde Aschheim, Landkreis Muenchen
Registergericht Muenchen, HRB Nr. 43632

Attachment: xen_xl.diff
Description: Text Data

Xen-devel mailing list
<Prev in Thread] Current Thread [Next in Thread>