[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

[libvirt] [PATCH 4/5] blockcopy: remote implementation for new API



Fairly straightforward.

* src/remote/remote_protocol.x (remote_domain_block_copy_args):
New struct.
(REMOTE_PROC_DOMAIN_BLOCK_COPY): New RPC.
* src/remote/remote_driver.c (remote_driver): Wire it up.

Signed-off-by: Eric Blake <eblake redhat com>
---
 src/remote/remote_driver.c   |  1 +
 src/remote/remote_protocol.x | 18 +++++++++++++++++-
 2 files changed, 18 insertions(+), 1 deletion(-)

diff --git a/src/remote/remote_driver.c b/src/remote/remote_driver.c
index 9a1d78f..98661be 100644
--- a/src/remote/remote_driver.c
+++ b/src/remote/remote_driver.c
@@ -7977,6 +7977,7 @@ static virDriver remote_driver = {
     .domainBlockJobSetSpeed = remoteDomainBlockJobSetSpeed, /* 0.9.4 */
     .domainBlockPull = remoteDomainBlockPull, /* 0.9.4 */
     .domainBlockRebase = remoteDomainBlockRebase, /* 0.9.10 */
+    .domainBlockCopy = remoteDomainBlockCopy, /* 1.2.8 */
     .domainBlockCommit = remoteDomainBlockCommit, /* 0.10.2 */
     .connectSetKeepAlive = remoteConnectSetKeepAlive, /* 0.9.8 */
     .connectIsAlive = remoteConnectIsAlive, /* 0.9.8 */
diff --git a/src/remote/remote_protocol.x b/src/remote/remote_protocol.x
index 5c316fb..81a8603 100644
--- a/src/remote/remote_protocol.x
+++ b/src/remote/remote_protocol.x
@@ -124,6 +124,9 @@ const REMOTE_DOMAIN_BLOCK_IO_TUNE_PARAMETERS_MAX = 16;
 /* Upper limit on list of numa parameters. */
 const REMOTE_DOMAIN_NUMA_PARAMETERS_MAX = 16;

+/* Upper limit on block copy tunable parameters. */
+const REMOTE_DOMAIN_BLOCK_COPY_PARAMETERS_MAX = 16;
+
 /* Upper limit on list of node cpu stats. */
 const REMOTE_NODE_CPU_STATS_MAX = 16;

@@ -1281,6 +1284,13 @@ struct remote_domain_block_rebase_args {
     unsigned hyper bandwidth;
     unsigned int flags;
 };
+struct remote_domain_block_copy_args {
+    remote_nonnull_domain dom;
+    remote_nonnull_string path;
+    remote_nonnull_string destxml;
+    remote_typed_param params<REMOTE_DOMAIN_BLOCK_COPY_PARAMETERS_MAX>;
+    unsigned int flags;
+};
 struct remote_domain_block_commit_args {
     remote_nonnull_domain dom;
     remote_nonnull_string disk;
@@ -5420,5 +5430,11 @@ enum remote_procedure {
      * @generate: both
      * @acl: connect:write
      */
-    REMOTE_PROC_CONNECT_GET_DOMAIN_CAPABILITIES = 342
+    REMOTE_PROC_CONNECT_GET_DOMAIN_CAPABILITIES = 342,
+
+    /**
+     * @generate: both
+     * @acl: domain:block_write
+     */
+    REMOTE_PROC_DOMAIN_BLOCK_COPY = 343
 };
-- 
1.9.3


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]