xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] libxc: reset completed flag in restore_ctx
@ 2011-05-23 23:05 Jim Fehlig
  2011-05-24  8:13 ` Ian Campbell
  2011-05-24 17:33 ` Ian Jackson
  0 siblings, 2 replies; 5+ messages in thread
From: Jim Fehlig @ 2011-05-23 23:05 UTC (permalink / raw)
  To: xen-devel

# HG changeset patch
# User Jim Fehlig <jfehlig@novell.com>
# Date 1306191873 21600
# Node ID f94242f20cdaee81d28f68df38d5a98f8fd9947d
# Parent  fb517cc27adef3a7ad548e7397e02e1414132ead
libxc: reset completed flag in restore_ctx

Long running libxl/libxc apps such as libvirt segfault when
attempting multiple restores.  The completed flag in restore_ctx
structure is set at completion of first restore.  Subsequent
restores do not load any pages and result in the segfault.

Reset completed flag at start of restore.

    Signed-off-by: Jim Fehlig <jfehlig@novell.com>

diff -r fb517cc27ade -r f94242f20cda tools/libxc/xc_domain_restore.c
--- a/tools/libxc/xc_domain_restore.c	Fri May 20 18:20:09 2011 +0100
+++ b/tools/libxc/xc_domain_restore.c	Mon May 23 17:04:33 2011 -0600
@@ -1146,6 +1146,7 @@ int xc_domain_restore(xc_interface *xch,
 
     /* For info only */
     ctx->nr_pfns = 0;
+    ctx->completed = 0;
 
     if ( superpages )
         return 1;

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2011-05-24 17:47 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-05-23 23:05 [PATCH] libxc: reset completed flag in restore_ctx Jim Fehlig
2011-05-24  8:13 ` Ian Campbell
2011-05-24 15:12   ` Jim Fehlig
2011-05-24 17:33 ` Ian Jackson
2011-05-24 17:47   ` Jim Fehlig

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).