[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH] proto: add 'shift' extension.
From: |
Alex Bligh |
Subject: |
Re: [Qemu-devel] [PATCH] proto: add 'shift' extension. |
Date: |
Mon, 26 Sep 2016 15:05:38 +0100 |
> On 26 Sep 2016, at 13:46, Vladimir Sementsov-Ogievskiy <address@hidden> wrote:
>
> #### Option reply types
>
> These values are used in the "reply type" field, sent by the server
> @@ -872,7 +883,13 @@ valid may depend on negotiation during the handshake
> phase.
>
> [extension](https://github.com/yoe/nbd/blob/extension-write-zeroes/doc/proto.md).
> - bit 2, `NBD_CMD_FLAG_DF`; defined by the experimental `STRUCTURED_REPLY`
>
> [extension](https://github.com/yoe/nbd/blob/extension-structured-reply/doc/proto.md).
> -
> +- bit 3, `NBD_CMD_FLAG_SHIFT`; This flag is valid for `NBD_CMD_TRIM` and
> + `NBD_CMD_WRITE_ZEROES`. If this flag is set the server shifts request
> + *length* and *offset* left by N bits, where N is defined by `NBD_OPT_SHIFT`
> + option or is assumed to be 16 bits by default if `NBD_OPT_SHIFT` option is
> + not specified. If after shift `(offset + length)` exceeds disk size, length
> + should be reduced to `(<disk size> - offset)`. However, `(offset + length)`
> + must not exceed disk size by more than `(1 << N) - 1`.
Is there a good reason the shift size can't be either the minimum block size
or otherwise negotiated using NBD_OPT_INFO?
--
Alex Bligh
- [Qemu-devel] [PATCH] proto: add 'shift' extension., Vladimir Sementsov-Ogievskiy, 2016/09/26
- Re: [Qemu-devel] [PATCH] proto: add 'shift' extension.,
Alex Bligh <=
- Re: [Qemu-devel] [PATCH] proto: add 'shift' extension., Eric Blake, 2016/09/26
- Re: [Qemu-devel] [PATCH] proto: add 'shift' extension., Denis V. Lunev, 2016/09/27
- Re: [Qemu-devel] [PATCH] proto: add 'shift' extension., Paolo Bonzini, 2016/09/27
- Re: [Qemu-devel] [PATCH] proto: add 'shift' extension., Denis V. Lunev, 2016/09/27
- Re: [Qemu-devel] [PATCH] proto: add 'shift' extension., Paolo Bonzini, 2016/09/27
- Re: [Qemu-devel] [PATCH] proto: add 'shift' extension., Denis V. Lunev, 2016/09/27
- Re: [Qemu-devel] [PATCH] proto: add 'shift' extension., Paolo Bonzini, 2016/09/27
- Re: [Qemu-devel] [PATCH] proto: add 'shift' extension., Denis V. Lunev, 2016/09/27