On 03/18/2011 10:36 AM, Daniel P. Berrange wrote:
* daemon/remote.c, src/remote/remote_driver.c: Implementation
of storage vol upload/download APIs
* src/remote/remote_protocol.x: Wire protocol definition for
upload/download
* daemon/remote_dispatch_args.h, daemon/remote_dispatch_prototypes.h,
daemon/remote_dispatch_table.h, src/remote/remote_protocol.h,
src/remote/remote_protocol.c: Re-generate
+++ b/src/remote/remote_driver.c
@@ -9563,6 +9563,91 @@ done:
return rv;
}
+static int
+remoteStorageVolUpload(virStorageVolPtr vol,
+ virStreamPtr st,
+ unsigned long long offset,
+ unsigned long long length,
+ unsigned int flags)
+{
+ struct private_data *priv = vol->conn->privateData;
+ struct private_stream_data *privst = NULL;
+ int rv = -1;
+ remote_storage_vol_upload_args args;
+
+ remoteDriverLock(priv);
+
+ if (!(privst = remoteStreamOpen(st, 1,
This looks a bit like a magic number, especially since the output
parameter of remoteStreamOpen is documented as ATTRIBUTE_UNUSED.
Overall, this patch looks pretty mechanical on top of the earlier patches.
--
Eric Blake eblake(a)redhat.com +1-801-349-2682
Libvirt virtualization library
http://libvirt.org