From: Ian Jackson Date: Wed, 17 Dec 2008 11:39:21 +0000 (+0000) Subject: stubdom: Fix live migration of HVM domain X-Git-Tag: xen-3.3.1 X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=dc5d4c02afc980392c3d48256783d6d3bd82f751;p=qemu-xen-3.3-testing.git stubdom: Fix live migration of HVM domain 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 (cherry picked from commit 7ed781aff412cff84a884405d99b0f1f7a629fc3) --- diff --git a/xenstore.c b/xenstore.c index c0fe95a5..dd487ddd 100644 --- a/xenstore.c +++ b/xenstore.c @@ -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 }