]> xenbits.xensource.com Git - people/liuw/libxenctrl-split/libvirt.git/commitdiff
blockjob: add blockcommit support to rpc
authorEric Blake <eblake@redhat.com>
Mon, 17 Sep 2012 20:07:18 +0000 (14:07 -0600)
committerEric Blake <eblake@redhat.com>
Tue, 18 Sep 2012 03:46:41 +0000 (21:46 -0600)
Relatively straightforward.  Our decision to make block job
speed a long keeps haunting us on new API.

* src/remote/remote_protocol.x (remote_domain_block_commit_args):
New struct.
* src/remote/remote_driver.c (remote_driver): Enable it.
* src/remote_protocol-structs: Regenerate.
* src/rpc/gendispatch.pl (long_legacy): Exempt another bandwidth.

src/remote/remote_driver.c
src/remote/remote_protocol.x
src/remote_protocol-structs
src/rpc/gendispatch.pl

index 8f3895de857bc3ed7c9c16e3c0a4c6eadaad5389..b6edf38bb298a86c37a711bea83a714ab94c61f7 100644 (file)
@@ -6045,6 +6045,7 @@ static virDriver remote_driver = {
     .domainBlockJobSetSpeed = remoteDomainBlockJobSetSpeed, /* 0.9.4 */
     .domainBlockPull = remoteDomainBlockPull, /* 0.9.4 */
     .domainBlockRebase = remoteDomainBlockRebase, /* 0.9.10 */
+    .domainBlockCommit = remoteDomainBlockCommit, /* 0.10.2 */
     .setKeepAlive = remoteSetKeepAlive, /* 0.9.8 */
     .isAlive = remoteIsAlive, /* 0.9.8 */
     .nodeSuspendForDuration = remoteNodeSuspendForDuration, /* 0.9.8 */
index 6201ff758ec5a7689e980f91fdd7b877d2d277e4..9481f151141a92233f27ad152eb3340224fa0d00 100644 (file)
@@ -1224,6 +1224,14 @@ struct remote_domain_block_rebase_args {
     unsigned hyper bandwidth;
     unsigned int flags;
 };
+struct remote_domain_block_commit_args {
+    remote_nonnull_domain dom;
+    remote_nonnull_string disk;
+    remote_string base;
+    remote_string top;
+    unsigned hyper bandwidth;
+    unsigned int flags;
+};
 
 struct remote_domain_set_block_io_tune_args {
     remote_nonnull_domain dom;
@@ -2988,7 +2996,9 @@ enum remote_procedure {
     REMOTE_PROC_CONNECT_LIST_ALL_NWFILTERS = 286, /* skipgen skipgen priority:high */
     REMOTE_PROC_CONNECT_LIST_ALL_SECRETS = 287, /* skipgen skipgen priority:high */
     REMOTE_PROC_NODE_SET_MEMORY_PARAMETERS = 288, /* autogen autogen */
-    REMOTE_PROC_NODE_GET_MEMORY_PARAMETERS = 289 /* skipgen skipgen */
+    REMOTE_PROC_NODE_GET_MEMORY_PARAMETERS = 289, /* skipgen skipgen */
+    REMOTE_PROC_DOMAIN_BLOCK_COMMIT = 290 /* autogen autogen */
+
 
     /*
      * Notice how the entries are grouped in sets of 10 ?
index 52ccf801525b9f84c211c3c5d39ef5be0d637f47..8b0ae1fe54866fb13a70728dc1cd50bc1f28f120 100644 (file)
@@ -875,6 +875,14 @@ struct remote_domain_block_rebase_args {
         uint64_t                   bandwidth;
         u_int                      flags;
 };
+struct remote_domain_block_commit_args {
+        remote_nonnull_domain      dom;
+        remote_nonnull_string      disk;
+        remote_string              base;
+        remote_string              top;
+        uint64_t                   bandwidth;
+        u_int                      flags;
+};
 struct remote_domain_set_block_io_tune_args {
         remote_nonnull_domain      dom;
         remote_nonnull_string      disk;
@@ -2397,4 +2405,5 @@ enum remote_procedure {
         REMOTE_PROC_CONNECT_LIST_ALL_SECRETS = 287,
         REMOTE_PROC_NODE_SET_MEMORY_PARAMETERS = 288,
         REMOTE_PROC_NODE_GET_MEMORY_PARAMETERS = 289,
+        REMOTE_PROC_DOMAIN_BLOCK_COMMIT = 290,
 };
index 774977de9b8fb1de14e10ed656d79cdfd5f8bf7e..ae7ecba499b4a031c5f208f56d4bfaa3a96d83eb 100755 (executable)
@@ -276,6 +276,7 @@ my $long_legacy = {
     GetLibVersion               => { ret => { lib_ver => 1 } },
     GetVersion                  => { ret => { hv_ver => 1 } },
     NodeGetInfo                 => { ret => { memory => 1 } },
+    DomainBlockCommit           => { arg => { bandwidth => 1 } },
     DomainBlockPull             => { arg => { bandwidth => 1 } },
     DomainBlockRebase           => { arg => { bandwidth => 1 } },
     DomainBlockJobSetSpeed      => { arg => { bandwidth => 1 } },