[libvirt] [PATCH 5/6] Remote protocol support for storage vol upload/download APIs

Eric Blake eblake at redhat.com
Mon Mar 21 21:37:14 UTC 2011


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 at redhat.com    +1-801-349-2682
Libvirt virtualization library http://libvirt.org

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 619 bytes
Desc: OpenPGP digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20110321/784d714a/attachment-0001.sig>


More information about the libvir-list mailing list