[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-block] [PATCH v3 11/13] nbd: share some nbd entities to be reu
From: |
Eric Blake |
Subject: |
Re: [Qemu-block] [PATCH v3 11/13] nbd: share some nbd entities to be reused in block/nbd-client.c |
Date: |
Fri, 13 Oct 2017 14:03:17 -0500 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.3.0 |
On 10/12/2017 04:53 AM, Vladimir Sementsov-Ogievskiy wrote:
> Signed-off-by: Vladimir Sementsov-Ogievskiy <address@hidden>
> ---
> include/block/nbd.h | 48 ++++++++++++++++++++++++++++++++++++++++++++++++
> nbd/nbd-internal.h | 25 -------------------------
> nbd/client.c | 32 --------------------------------
> 3 files changed, 48 insertions(+), 57 deletions(-)
>
Another thing I noticed looking at this patch:
> diff --git a/include/block/nbd.h b/include/block/nbd.h
> index dd261f66f0..09e4592971 100644
> --- a/include/block/nbd.h
> +++ b/include/block/nbd.h
> @@ -77,6 +77,9 @@ typedef struct NBDStructuredReplyChunk {
> uint32_t length; /* length of payload */
> } QEMU_PACKED NBDStructuredReplyChunk;
>
> +#define NBD_SIMPLE_REPLY_MAGIC 0x67446698
> +#define NBD_STRUCTURED_REPLY_MAGIC 0x668e33ef
We have some churn here, as we defined this earlier in the series.
Also, in an ideal world (although I don't know if we're quite there), we
should be able to backport patches for JUST the server, or for JUST the
client, in isolation, to talk to an independent implementation on the
other side of the wire. To do that, it may be better to define all our
new constants in a standalone patch, rather than embedded as part of the
server implementation in 9/13.
I think at this point, I will take 1-8 as amended, and even prepare a
pull request for those, and then post a v4 series based on your work but
with some things moved around, and get consensus on my changes, before
worrying about the pull request for the second half.
--
Eric Blake, Principal Software Engineer
Red Hat, Inc. +1-919-301-3266
Virtualization: qemu.org | libvirt.org
signature.asc
Description: OpenPGP digital signature
- Re: [Qemu-block] [Qemu-devel] [PATCH v3 07/13] nbd-server: simplify reply transmission, (continued)
- [Qemu-block] [PATCH v3 02/13] block/nbd-client: refactor nbd_co_receive_reply, Vladimir Sementsov-Ogievskiy, 2017/10/12
- [Qemu-block] [PATCH v3 06/13] nbd/server: refactor nbd_co_send_simple_reply parameters, Vladimir Sementsov-Ogievskiy, 2017/10/12
- [Qemu-block] [PATCH v3 01/13] block/nbd-client: assert qiov len once in nbd_co_request, Vladimir Sementsov-Ogievskiy, 2017/10/12
- [Qemu-block] [PATCH v3 11/13] nbd: share some nbd entities to be reused in block/nbd-client.c, Vladimir Sementsov-Ogievskiy, 2017/10/12
- [Qemu-block] [PATCH v3 10/13] nbd/client: refactor nbd_receive_starttls, Vladimir Sementsov-Ogievskiy, 2017/10/12
- [Qemu-block] [PATCH v3 08/13] nbd: header constants indenting, Vladimir Sementsov-Ogievskiy, 2017/10/12
- [Qemu-block] [PATCH v3 03/13] nbd: rename some simple-request related objects to be _simple_, Vladimir Sementsov-Ogievskiy, 2017/10/12
- [Qemu-block] [PATCH v3 12/13] nbd/client: prepare nbd_receive_reply for structured reply, Vladimir Sementsov-Ogievskiy, 2017/10/12
- [Qemu-block] [PATCH v3 05/13] nbd/server: do not use NBDReply structure, Vladimir Sementsov-Ogievskiy, 2017/10/12