[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v6 4/4] new qTest case to test the vhost-user-blk-server
From: |
Thomas Huth |
Subject: |
Re: [PATCH v6 4/4] new qTest case to test the vhost-user-blk-server |
Date: |
Thu, 4 Jun 2020 15:42:20 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.9.0 |
On 30/05/2020 19.14, Coiby Xu wrote:
> This test case has the same tests as tests/virtio-blk-test.c except for
> tests have block_resize. Since vhost-user server can only server one
> client one time, two instances of qemu-storage-daemon are launched
> for the hotplug test.
>
> In order to not block scripts/tap-driver.pl, 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.
>
> Signed-off-by: Coiby Xu <coiby.xu@gmail.com>
> ---
> tests/Makefile.include | 3 +-
> tests/qtest/Makefile.include | 2 +
> tests/qtest/libqos/vhost-user-blk.c | 126 +++++
> tests/qtest/libqos/vhost-user-blk.h | 44 ++
> tests/qtest/libqtest.c | 44 +-
> tests/qtest/libqtest.h | 38 ++
> tests/qtest/vhost-user-blk-test.c | 741 ++++++++++++++++++++++++++++
> 7 files changed, 966 insertions(+), 32 deletions(-)
> create mode 100644 tests/qtest/libqos/vhost-user-blk.c
> create mode 100644 tests/qtest/libqos/vhost-user-blk.h
> create mode 100644 tests/qtest/vhost-user-blk-test.c
[...]
> qos-test-obj-y += tests/qtest/virtio-scsi-test.o
> diff --git a/tests/qtest/libqos/vhost-user-blk.c
> b/tests/qtest/libqos/vhost-user-blk.c
> new file mode 100644
> index 0000000000..ec46b7ddb4
> --- /dev/null
> +++ b/tests/qtest/libqos/vhost-user-blk.c
> @@ -0,0 +1,126 @@
> +/*
> + * libqos driver framework
> + *
> + * Copyright (c) 2018 Emanuele Giuseppe Esposito
> <e.emanuelegiuseppe@gmail.com>
Don't you want to add a remark here for you, too?
> + * This library is free software; you can redistribute it and/or
> + * modify it under the terms of the GNU Lesser General Public
> + * License version 2 as published by the Free Software Foundation.
Could you please change "version 2" into "verion 2.1" ? There never was
a "version 2" of the LGPL, only version 2.1 (or 3.x).
(I know, we still got these wrong in a lot of other files, but at least
we should try to get it right in new files..)
> + * This library is distributed in the hope that it will be useful,
> + * but WITHOUT ANY WARRANTY; without even the implied warranty of
> + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
> + * Lesser General Public License for more details.
> + *
> + * You should have received a copy of the GNU Lesser General Public
> + * License along with this library; if not, see
> <http://www.gnu.org/licenses/>
> + */
> diff --git a/tests/qtest/libqos/vhost-user-blk.h
> b/tests/qtest/libqos/vhost-user-blk.h
> new file mode 100644
> index 0000000000..ef4ef09cca
> --- /dev/null
> +++ b/tests/qtest/libqos/vhost-user-blk.h
> @@ -0,0 +1,44 @@
> +/*
> + * libqos driver framework
> + *
> + * Copyright (c) 2018 Emanuele Giuseppe Esposito
> <e.emanuelegiuseppe@gmail.com>
> + *
> + * This library is free software; you can redistribute it and/or
> + * modify it under the terms of the GNU Lesser General Public
> + * License version 2 as published by the Free Software Foundation.
dito.
Thanks,
Thomas
- Re: [PATCH v6 4/4] new qTest case to test the vhost-user-blk-server,
Thomas Huth <=