aboutsummaryrefslogtreecommitdiffstats
path: root/tools/libxc/xenguest.h
diff options
context:
space:
mode:
authorPaul Durrant <paul.durrant@citrix.com>2011-12-16 14:54:14 +0000
committerPaul Durrant <paul.durrant@citrix.com>2011-12-16 14:54:14 +0000
commit8f76fc6c983e3bf7c8c32fae2c7264f718e2b467 (patch)
treea279f798e76580f86bffe3f632a0eb276859665d /tools/libxc/xenguest.h
parentbe9b274df12d03fe2366fdbb58a37f537c3d2ff1 (diff)
downloadxen-8f76fc6c983e3bf7c8c32fae2c7264f718e2b467.tar.gz
xen-8f76fc6c983e3bf7c8c32fae2c7264f718e2b467.tar.bz2
xen-8f76fc6c983e3bf7c8c32fae2c7264f718e2b467.zip
tools: VM generation ID save/restore and migrate.
Add code to track the address of the VM generation ID buffer across a save/restore or migrate, and increment it as necessary. The address of the buffer is written into xenstore by hvmloader at boot time. It must be read from xenstore by the caller of xc_domain_save() and then written back again by the caller of xc_domain_restore(). Note that the changes to xc_save.c and xc_restore.c are merely sufficient for them to build. Signed-off-by: Paul Durrant <paul.durrant@citrix.com> Committed-by: Ian Jackson <ian.jackson.citrix.com>
Diffstat (limited to 'tools/libxc/xenguest.h')
-rw-r--r--tools/libxc/xenguest.h9
1 files changed, 7 insertions, 2 deletions
diff --git a/tools/libxc/xenguest.h b/tools/libxc/xenguest.h
index 4475ee92ee..60263709ce 100644
--- a/tools/libxc/xenguest.h
+++ b/tools/libxc/xenguest.h
@@ -58,7 +58,8 @@ struct save_callbacks {
*/
int xc_domain_save(xc_interface *xch, int io_fd, uint32_t dom, uint32_t max_iters,
uint32_t max_factor, uint32_t flags /* XCFLAGS_xxx */,
- struct save_callbacks* callbacks, int hvm);
+ struct save_callbacks* callbacks, int hvm,
+ unsigned long vm_generationid_addr);
/**
@@ -72,12 +73,16 @@ int xc_domain_save(xc_interface *xch, int io_fd, uint32_t dom, uint32_t max_iter
* @parm hvm non-zero if this is a HVM restore
* @parm pae non-zero if this HVM domain has PAE support enabled
* @parm superpages non-zero to allocate guest memory with superpages
+ * @parm no_incr_generationid non-zero if generation id is NOT to be incremented
+ * @parm vm_generationid_addr returned with the address of the generation id buffer
* @return 0 on success, -1 on failure
*/
int xc_domain_restore(xc_interface *xch, int io_fd, uint32_t dom,
unsigned int store_evtchn, unsigned long *store_mfn,
unsigned int console_evtchn, unsigned long *console_mfn,
- unsigned int hvm, unsigned int pae, int superpages);
+ unsigned int hvm, unsigned int pae, int superpages,
+ int no_incr_generationid,
+ unsigned long *vm_generationid_addr);
/**
* xc_domain_restore writes a file to disk that contains the device
* model saved state.