Re: [Qemu-devel] [PATCH 1/1] nbd: implement bdrv_get_info callback

2018-01-26 Thread Edgar Kaziakhmedov
PIng So, let me know if I need to make any changes in patch On 1/18/18 1:09 PM, Paolo Bonzini wrote: On 18/01/2018 12:51, Edgar Kaziakhmedov wrote: +static int nbd_get_info(BlockDriverState *bs, BlockDriverInfo *bdi) +{ +if (bs->supported_zero_flags & BDRV_REQ_MAY_UNMAP) { +

Re: [Qemu-devel] [PATCH 1/1] nbd: implement bdrv_get_info callback

2018-02-02 Thread Edgar Kaziakhmedov
On 01/26/2018 05:28 PM, Eric Blake wrote: On 01/26/2018 06:39 AM, Edgar Kaziakhmedov wrote: PIng So, let me know if I need to make any changes in patch On 1/18/18 1:09 PM, Paolo Bonzini wrote: On 18/01/2018 12:51, Edgar Kaziakhmedov wrote: +static int nbd_get_info(BlockDriverState *bs

Re: [Qemu-devel] [PATCH 1/1] nbd: implement bdrv_get_info callback

2018-02-02 Thread Edgar Kaziakhmedov
On 02/02/2018 05:15 PM, Eric Blake wrote: On 02/02/2018 08:06 AM, Edgar Kaziakhmedov wrote: However, it would be nice to remove can_write_zeroes_with_unmap from BlockDriverInfo, and make bdrv_can_write_zeroes_with_unmap just return !!(bs->supported_zero_flags & BDRV_REQ_MAY_UNMAP).

[Qemu-devel] [PATCH] qcow2: get rid of qcow2_backing_read1 routine

2017-12-12 Thread Edgar Kaziakhmedov
Since bdrv_co_preadv does all neccessary checks including reading after the end of the backing file, avoid duplication of verification before bdrv_co_preadv call. Signed-off-by: Edgar Kaziakhmedov Reviewed-by: Vladimir Sementsov-Ogievskiy --- block/qcow2.c | 51

[Qemu-devel] [PATCH 1/1] nbd: implement bdrv_get_info callback

2018-01-18 Thread Edgar Kaziakhmedov
: Edgar Kaziakhmedov --- block/nbd.c | 11 +++ 1 file changed, 11 insertions(+) diff --git a/block/nbd.c b/block/nbd.c index 8b8ba56cdd..94220f6d14 100644 --- a/block/nbd.c +++ b/block/nbd.c @@ -566,6 +566,14 @@ static void nbd_refresh_filename(BlockDriverState *bs, QDict *options) bs

Re: [Qemu-devel] [PATCH 1/1] io/channel-websock: handle continuous reads without any data

2018-01-10 Thread Edgar Kaziakhmedov
ping On 12/28/2017 12:36 PM, Denis V. Lunev wrote: From: Edgar Kaziakhmedov According to the current implementation of websocket protocol in QEMU, qio_channel_websock_handshake_io tries to read handshake from the channel to start communication over tcp socket. But this subroutine doesn&#

Re: [Qemu-devel] [PATCH 1/1] io/channel-websock: handle continuous reads without any data

2018-01-10 Thread Edgar Kaziakhmedov
On 01/10/2018 03:33 PM, Daniel P. Berrange wrote: On Thu, Dec 28, 2017 at 12:36:18PM +0300, Denis V. Lunev wrote: From: Edgar Kaziakhmedov According to the current implementation of websocket protocol in QEMU, qio_channel_websock_handshake_io tries to read handshake from the channel to

[Qemu-devel] [PATCH v2 1/1] io/channel-websock: handle continuous reads without any data

2018-01-10 Thread Edgar Kaziakhmedov
plest configuration $ qemu -vnc [::1]:1,websocket=7500 2) open any vnc listener (which doesn't follow websocket protocol) $ vncviewer :7500 3) kill listener 4) qemu main thread eats 100% CPU Signed-off-by: Edgar Kaziakhmedov --- io/channel-websock.c | 14 -- 1 file changed, 12 insert

Re: [Qemu-devel] [PATCH v2 1/1] io/channel-websock: handle continuous reads without any data

2018-01-10 Thread Edgar Kaziakhmedov
On 01/10/2018 06:22 PM, Daniel P. Berrange wrote: On Wed, Jan 10, 2018 at 06:13:22PM +0300, Edgar Kaziakhmedov wrote: According to the current implementation of websocket protocol in QEMU, qio_channel_websock_handshake_io tries to read handshake from the channel to start communication over

[Qemu-devel] [PATCH v3 1/1] io/channel-websock: handle continuous reads without any data

2018-01-10 Thread Edgar Kaziakhmedov
plest configuration $ qemu -vnc [::1]:1,websocket=7500 2) open any vnc listener (which doesn't follow websocket protocol) $ vncviewer :7500 3) kill listener 4) qemu main thread eats 100% CPU Signed-off-by: Edgar Kaziakhmedov --- io/channel-websock.c | 7 +-- 1 file changed, 5 insertions(+), 2

Re: [Qemu-devel] Some thoughts about per-queue iothreads in VirtIOBlock

2018-04-03 Thread Edgar Kaziakhmedov
On 4/3/18 3:27 PM, Stefan Hajnoczi wrote: On Tue, Mar 20, 2018 at 07:30:04PM +0300, Edgar Kaziakhmedov wrote: On 3/20/18 6:34 PM, Paolo Bonzini wrote: On 20/03/2018 15:45, Edgar Kaziakhmedov wrote: As I understood from Stefan description, it is expected to change significantly the approach

[Qemu-devel] Some thoughts about per-queue iothreads in VirtIOBlock

2018-03-20 Thread Edgar Kaziakhmedov
Hi! Recently, I have started working on the real multi-queue implementation for the VirtIOBlock device and came to conclusion that for the time being it may work only with RAW images. The reason is obviously lack of the true thread-safe multi-queue block layer, but recently I have seen the fol

Re: [Qemu-devel] Some thoughts about per-queue iothreads in VirtIOBlock

2018-03-20 Thread Edgar Kaziakhmedov
On 3/20/18 6:34 PM, Paolo Bonzini wrote: On 20/03/2018 15:45, Edgar Kaziakhmedov wrote: As I understood from Stefan description, it is expected to change significantly the approach we use to interact with BlockDriverState. I don't think the change is very large actually, at least for on

[Qemu-devel] [PATCH 1/1] nbd: increase maximum size of the PWRITE_ZERO request

2018-02-08 Thread Edgar Kaziakhmedov
o 1Gb (aligned). Moreover, such change will decrease the number of PWRITE_ZERO NBD commands in comparison with the current 32M limit. The benefits of the larger constraint can be examined in a block mirroring over NBD. Signed-off-by: Edgar Kaziakhmedov --- block/nbd.c | 2 +- include/block/

Re: [Qemu-devel] [PATCH 1/1] nbd: increase maximum size of the PWRITE_ZERO request

2018-02-08 Thread Edgar Kaziakhmedov
On 02/08/2018 05:54 PM, Eric Blake wrote: On 02/08/2018 07:23 AM, Edgar Kaziakhmedov wrote: Upstream NBD protocol implementation supports an efficient zero out mechanism over the wire, along with the ability to check whether a client allows using a hole. Accordingly, since PWRITE_ZERO

Re: [Qemu-devel] [PATCH 1/1] nbd: increase maximum size of the PWRITE_ZERO request

2018-02-08 Thread Edgar Kaziakhmedov
On 02/08/2018 06:55 PM, Eric Blake wrote: On 02/08/2018 09:28 AM, Edgar Kaziakhmedov wrote: We've got a potential problem.  Unless you have out-of-band communication of the maximum NBD_CMD_WRITE_ZEROES sizing (or if the NBD protocol is enhanced to advertise that as an additional pie