]> xenbits.xensource.com Git - qemu-xen-3.3-testing.git/commitdiff
stubdom: Fix live migration of HVM domain xen-3.3.1 xen-3.3.1-rc3 xen-3.3.1-rc4
authorIan Jackson <ian.jackson@eu.citrix.com>
Wed, 17 Dec 2008 11:39:21 +0000 (11:39 +0000)
committerIan Jackson <Ian.Jackson@eu.citrix.com>
Wed, 17 Dec 2008 13:24:23 +0000 (13:24 +0000)
Live-migration fails because stubdom-dm doesn't respond to the request
from xc_save for the logdirty bitmap segment. The attached patch
simply generated from old ioemu tree will fix the issue, then.

Derived from old xen internal tools/ioemu tree.

Signed-off-by: Yosuke Iwamatsu <y-iwamatsu@ab.jp.nec.com>
(cherry picked from commit 7ed781aff412cff84a884405d99b0f1f7a629fc3)

xenstore.c

index c0fe95a50db07d022bea3c17464a75ae44179f7a..dd487ddd08505b0327bec8fd788ddbd7dd25fdae 100644 (file)
@@ -440,10 +440,6 @@ extern int vga_ram_size, bios_size;
 
 void xenstore_process_logdirty_event(void)
 {
-#ifdef CONFIG_STUBDOM
-    /* XXX we just can't use shm. */
-    return;
-#else
     char *act;
     static char *active_path = NULL;
     static char *next_active_path = NULL;
@@ -471,6 +467,10 @@ void xenstore_process_logdirty_event(void)
             /* No key yet: wait for the next watch */
             return;
 
+#ifdef CONFIG_STUBDOM
+        /* We pass the writes to hypervisor */
+        seg = (void*)1;
+#else
         strncpy(key_terminated, key_ascii, 16);
         free(key_ascii);
         key = (key_t) strtoull(key_terminated, NULL, 16);
@@ -510,6 +510,7 @@ void xenstore_process_logdirty_event(void)
             seg = NULL;
             return;
         }
+#endif
 
         /* Remember the paths for the next-active and active entries */
         if (pasprintf(&active_path, 
@@ -546,7 +547,6 @@ void xenstore_process_logdirty_event(void)
     /* Ack that we've switched */
     xs_write(xsh, XBT_NULL, active_path, act, len);
     free(act);
-#endif
 }