[PATCH v10 4/7] block: move logical block size check function to a common utility function

2020-09-18 Thread Coiby Xu
Move the constants from hw/core/qdev-properties.c to util/block-helpers.h so that knowledge of the min/max values is Signed-off-by: Stefan Hajnoczi Signed-off-by: Coiby Xu --- hw/core/qdev-properties.c | 31 +- util/block-helpers.c | 46

[PATCH v10 6/7] test: new qTest case to test the vhost-user-blk-server

2020-09-18 Thread Coiby Xu
, vhost-user-blk-server will send "quit" command to qemu-storage-daemon's QMP monitor. So a function is added to libqtest.c to establish socket connection with socket server. Suggested-by: Thomas Huth Signed-off-by: Coiby Xu --- tests/qtest/libqos/libqtest.h | 17 + tes

[PATCH v10 5/7] block/export: vhost-user block device backend server

2020-09-18 Thread Coiby Xu
: Stefan Hajnoczi Signed-off-by: Coiby Xu --- block/export/vhost-user-blk-server.c | 661 +++ block/export/vhost-user-blk-server.h | 36 ++ block/meson.build| 1 + softmmu/vl.c | 4 + 4 files changed, 702 insertions(+) create

[PATCH v10 7/7] MAINTAINERS: Add vhost-user block device backend server maintainer

2020-09-18 Thread Coiby Xu
Suggested-by: Stefano Garzarella Signed-off-by: Coiby Xu --- MAINTAINERS | 8 1 file changed, 8 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index 3d17cad19a..55ad6abe73 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -3039,6 +3039,14 @@ L: qemu-bl...@nongnu.org S: Supported F

Re: [PATCH v9 0/5] vhost-user block device backend implementation

2020-09-18 Thread Coiby Xu
On Tue, Sep 15, 2020 at 04:35:57PM +0100, Stefan Hajnoczi wrote: On Mon, Jun 15, 2020 at 02:39:02AM +0800, Coiby Xu wrote: v9 - move logical block size check function to a utility function - fix issues regarding license, coding style, memory deallocation, etc. Hi, Any update on v10? Please

Re: [PATCH v8 0/4] vhost-user block device backend implementation

2020-06-12 Thread Coiby Xu
On Thu, Jun 11, 2020 at 04:27:44PM +0100, Stefan Hajnoczi wrote: On Fri, Jun 05, 2020 at 07:35:34AM +0800, Coiby Xu wrote: v8 - re-try connecting to socket server to fix asan error - fix license naming issue Great, thanks for posting these patches! I have posted feedback. I'd like to

[PATCH v9 0/5] vhost-user block device backend implementation

2020-06-14 Thread Coiby Xu
could act as a client, $ -m 256 -object memory-backend-memfd,id=mem,size=256M,share=on -numa node,memdev=mem -chardev socket,id=char1,path=/tmp/vhost-user-blk_vhost.socket -device vhost-user-blk-pci,id=blk0,chardev=char1 And guest OS could access this vhost-user block device after mounting it

[PATCH v9 2/5] generic vhost user server

2020-06-14 Thread Coiby Xu
Sharing QEMU devices via vhost-user protocol. Only one vhost-user client can connect to the server one time. Signed-off-by: Coiby Xu --- util/Makefile.objs | 1 + util/vhost-user-server.c | 400 +++ util/vhost-user-server.h | 61 ++ 3 files

[PATCH v9 3/5] move logical block size check function to a common utility function

2020-06-14 Thread Coiby Xu
Move logical block size check function in hw/core/qdev-properties.c:set_blocksize() to util/block-helpers.c Signed-off-by: Coiby Xu --- hw/core/qdev-properties.c | 18 +++ util/Makefile.objs| 1 + util/block-helpers.c | 46 +++ util

[PATCH v9 4/5] vhost-user block device backend server

2020-06-14 Thread Coiby Xu
By making use of libvhost-user, block device drive can be shared to the connected vhost-user client. Only one client can connect to the server one time. Since vhost-user-server needs a block drive to be created first, delay the creation of this object. Signed-off-by: Coiby Xu --- block

[PATCH v9 1/5] Allow vu_message_read to be replaced

2020-06-14 Thread Coiby Xu
Allow vu_message_read to be replaced by one which will make use of the QIOChannel functions. Thus reading vhost-user message won't stall the guest. Signed-off-by: Coiby Xu --- contrib/libvhost-user/libvhost-user-glib.c | 2 +- contrib/libvhost-user/libvhost-user.c

[PATCH v9 5/5] new qTest case to test the vhost-user-blk-server

2020-06-14 Thread Coiby Xu
will send "quit" command to qemu-storage-daemon's QMP monitor. So a function is added to libqtest.c to establish socket connection with socket server. Signed-off-by: Coiby Xu --- tests/Makefile.include | 3 +- tests/qtest/Makefile.include| 2 + tests/qte

Re: [PATCH v8 2/4] generic vhost user server

2020-06-14 Thread Coiby Xu
On Thu, Jun 11, 2020 at 02:14:49PM +0100, Stefan Hajnoczi wrote: On Fri, Jun 05, 2020 at 07:35:36AM +0800, Coiby Xu wrote: +static bool coroutine_fn +vu_message_read(VuDev *vu_dev, int conn_fd, VhostUserMsg *vmsg) +{ +struct iovec iov = { +.iov_base = (char *)vmsg, +.iov_len

Re: [PATCH v8 0/4] vhost-user block device backend implementation

2020-06-14 Thread Coiby Xu
Hi Stefano Garzarella, On Thu, Jun 11, 2020 at 02:37:03PM +0200, Stefano Garzarella wrote: Hi Coiby Xu, On Fri, Jun 05, 2020 at 07:35:34AM +0800, Coiby Xu wrote: v8 - re-try connecting to socket server to fix asan error - fix license naming issue v7 - fix docker-test-debug@fedora errors

Re: [PATCH v8 3/4] vhost-user block device backend server

2020-06-14 Thread Coiby Xu
On Thu, Jun 11, 2020 at 04:24:52PM +0100, Stefan Hajnoczi wrote: On Fri, Jun 05, 2020 at 07:35:37AM +0800, Coiby Xu wrote: +static void coroutine_fn vu_block_virtio_process_req(void *opaque) +{ +struct req_data *data = opaque; +VuServer *server = data->server; +VuVirtq *vq = d

Re: [PATCH v9 0/5] vhost-user block device backend implementation

2020-06-16 Thread Coiby Xu
On Sun, Jun 14, 2020 at 12:16:28PM -0700, no-re...@patchew.org wrote: Patchew URL: https://patchew.org/QEMU/20200614183907.514282-1-coiby...@gmail.com/ Hi, This series failed the asan build test. Please find the testing commands and their output below. If you have Docker installed, you can p

Re: [PATCH v8 0/4] vhost-user block device backend implementation

2020-06-16 Thread Coiby Xu
On Mon, Jun 15, 2020 at 10:46:10AM +0200, Stefano Garzarella wrote: On Mon, Jun 15, 2020 at 02:46:40AM +0800, Coiby Xu wrote: Hi Stefano Garzarella, On Thu, Jun 11, 2020 at 02:37:03PM +0200, Stefano Garzarella wrote: > Hi Coiby Xu, > > On Fri, Jun 05, 2020 at 07:35:34AM +0800, Coiby

<    1   2