From: "Michael S. Tsirkin" <mst@redhat.com>
To: Stefano Garzarella <sgarzare@redhat.com>
Cc: qemu-devel@nongnu.org, "Coiby Xu" <Coiby.Xu@gmail.com>,
"Kevin Wolf" <kwolf@redhat.com>,
"Philippe Mathieu-Daudé" <philmd@linaro.org>,
stefanha@redhat.com, "Markus Armbruster" <armbru@redhat.com>,
slp@redhat.com, "Eduardo Habkost" <eduardo@habkost.net>,
"David Hildenbrand" <david@redhat.com>,
"Raphael Norwitz" <raphael@enfabrica.net>,
"Marc-André Lureau" <marcandre.lureau@redhat.com>,
"Daniel P. Berrangé" <berrange@redhat.com>,
"Igor Mammedov" <imammedo@redhat.com>,
"Gerd Hoffmann" <kraxel@redhat.com>,
"Thomas Huth" <thuth@redhat.com>,
qemu-block@nongnu.org, "Brad Smith" <brad@comstyle.com>,
"Hanna Reitz" <hreitz@redhat.com>,
"Eric Blake" <eblake@redhat.com>,
gmaglione@redhat.com, "Paolo Bonzini" <pbonzini@redhat.com>,
"Jason Wang" <jasowang@redhat.com>,
"Laurent Vivier" <lvivier@redhat.com>
Subject: Re: [PATCH v8 00/13] vhost-user: support any POSIX system (tested on macOS, FreeBSD, OpenBSD)
Date: Fri, 5 Jul 2024 04:49:17 -0400 [thread overview]
Message-ID: <20240705044754-mutt-send-email-mst@kernel.org> (raw)
In-Reply-To: <suvpzkb3ppdodjdyo5zcpngz5mwrrlq3nfowemh4tqjghbc4si@hzrsr23fganv>
On Fri, Jul 05, 2024 at 10:39:33AM +0200, Stefano Garzarella wrote:
> On Wed, Jul 03, 2024 at 06:49:30PM GMT, Michael S. Tsirkin wrote:
> > On Tue, Jun 18, 2024 at 12:00:30PM +0200, Stefano Garzarella wrote:
> > > As discussed with Michael and Markus [1], this version also includes the patch
> > > on which v7 depended to simplify the merge in Michael's tree.
> > >
> > > The series is all reviewed, so if there are no new changes required, I would
> > > ask to merge it.
> >
> >
> > I dropped patches 9 and 10 for now since otherwise make vm-build-freebsd
> > fails.
> >
> > Pls figure it out and resend just 9 and 10.
>
> I replicated locally, but I can't understand why it only happens in certain
> architectures, in my case on loongarch64, ppc64, and riscv32:
>
> 326/846 qemu:qtest+qtest-loongarch64 / qtest-loongarch64/qos-test
> ERROR 116.10s killed by signal 6 SIGABRT
> 337/846 qemu:qtest+qtest-ppc64 / qtest-ppc64/qos-test
> ERROR 115.10s killed by signal 6 SIGABRT
> 339/846 qemu:qtest+qtest-riscv32 / qtest-riscv32/qos-test
> ERROR 107.65s killed by signal 6 SIGABRT
>
> I focused on ppc64 running `gmake --output-sync -j6 check-qtest-ppc64` in
> the FreeBSD VM and it fails every time. In particular, the test that fails
> is the `vhost-user/reconnect` test, in fact disabling it this way, the
> qos-test tests always pass:
>
> diff --git a/tests/qtest/vhost-user-test.c b/tests/qtest/vhost-user-test.c
> index 0fa8951c9f..c3d686f0ee 100644
> --- a/tests/qtest/vhost-user-test.c
> +++ b/tests/qtest/vhost-user-test.c
> @@ -1118,9 +1119,11 @@ static void register_vhost_user_test(void)
> "virtio-net",
> test_migrate, &opts);
>
> +#if 0
> opts.before = vhost_user_test_setup_reconnect;
> qos_add_test("vhost-user/reconnect", "virtio-net",
> test_reconnect, &opts);
> +#endif
>
> opts.before = vhost_user_test_setup_connect_fail;
> qos_add_test("vhost-user/connect-fail", "virtio-net",
>
> Analyzing the test, what happens is that after the disconnection, the test
> doesn't receive VHOST_USER_SET_MEM_TABLE message, so the second
> `wait_for_fds()` fails after the 5 sec timeout (increasing it doesn't help),
> not having received the fds.
>
> diff --git a/tests/qtest/vhost-user-test.c b/tests/qtest/vhost-user-test.c
> index 0fa8951c9f..c3d686f0ee 100644
> --- a/tests/qtest/vhost-user-test.c
> +++ b/tests/qtest/vhost-user-test.c
> @@ -976,6 +976,7 @@ static void test_reconnect(void *obj, void *arg,
> QGuestAllocator *alloc)
> g_source_set_callback(src, reconnect_cb, s, NULL);
> g_source_attach(src, s->context);
> g_source_unref(src);
> + // THIS one is failing
> g_assert(wait_for_fds(s));
> wait_for_rings_started(s, 2);
> }
>
> This is the test log (note: IIUC QEMU failures happen after the test exits
> on the assertion, so so it could mean that the chardev reconnected
> correctly):
>
> ▶ 28/30 /ppc64/pseries/spapr-pci-host-bridge/pci-bus-spapr/pci-bus/virtio-net-pci/virtio-net/virtio-net-tests/vhost-user/reconnect - ERROR:../src/tests/qtest/qos-test.c:191:subprocess_run_one_test: child process (/ppc64/pseries/spapr-pci-host-bridge/pci-bus-spapr/pci-bus/virtio-net-pci/virtio-net/virtio-net-tests/vhost-user/reconnect/subprocess [54991]) failed unexpectedly FAIL
> ▶ 28/30 ERROR
> [28-30/30] 🌒 qemu:qtest+qtest-ppc64 / qtest-ppc64/qmp-cmd-test [28-30/30] 🌓 qemu:qtest+qtest-ppc64 / qtest-ppc64/migration-test 28/30 qemu:qtest+qtest-ppc64 / qtest-ppc64/qos-test ERROR 21.53s killed by signal 6 SIGABRT
> >>> PYTHON=/usr/home/qemu/qemu-test.OD8v2L/build/pyvenv/bin/python3.9 ASAN_OPTIONS=halt_on_error=1:abort_on_error=1:print_summary=1 G_TEST_DBUS_DAEMON=/usr/home/qemu/qemu-test.OD8v2L/src/tests/dbus-vmstate-daemon.sh QTEST_QEMU_BINARY=./qemu-system-ppc64 MALLOC_PERTURB_=141 QTEST_QEMU_IMG=./qemu-img QTEST_QEMU_STORAGE_DAEMON_BINARY=./storage-daemon/qemu-storage-daemon UBSAN_OPTIONS=halt_on_error=1:abort_on_error=1:print_summary=1:print_stacktrace=1 /usr/home/qemu/qemu-test.OD8v2L/build/tests/qtest/qos-test --tap -k
> ―――――――――――――――――――――――――――――――――――――――― ✀ ――――――――――――――――――――――――――――――――――――――――
> stderr:
> Vhost user backend fails to broadcast fake RARP
> qemu-system-ppc64: -chardev socket,id=chr-reconnect,path=/tmp/vhost-test-Z5VMQ2/reconnect.sock,server=on: info: QEMU waiting for connection on: disconnected:unix:/tmp/vhost-test-Z5VMQ2/reconnect.sock,server=on
> **
> ERROR:../src/tests/qtest/vhost-user-test.c:255:wait_for_fds: assertion failed: (s->fds_num)
> qemu-system-ppc64: Failed to set msg fds.
> qemu-system-ppc64: vhost VQ 0 ring restore failed: -22: Invalid argument (22)
> qemu-system-ppc64: Failed to set msg fds.
> qemu-system-ppc64: vhost_set_vring_endian failed: Invalid argument (22)
> qemu-system-ppc64: Failed to set msg fds.
> qemu-system-ppc64: vhost VQ 1 ring restore failed: -22: Invalid argument
> (22)
> qemu-system-ppc64: Failed to set msg fds.
> qemu-system-ppc64: vhost_set_vring_endian failed: Invalid argument (22)
> qemu-system-ppc64: Failed to write msg. Wrote -1 instead of 12.
> qemu-system-ppc64: vhost_backend_init failed: Protocol error
> qemu-system-ppc64: failed to init vhost_net for queue 0
> **
> ERROR:../src/tests/qtest/qos-test.c:191:subprocess_run_one_test: child process (/ppc64/pseries/spapr-pci-host-bridge/pci-bus-spapr/pci-bus/virtio-net-pci/virtio-net/virtio-net-tests/vhost-user/reconnect/subprocess [54991]) failed unexpectedly
> (test program exited with status code -6)
>
>
> I would think of some endianness problem, but it's strange that it only
> happens in the reconnect test.
loongarch64 is LE and I think so is riscv in practice.
> Next week I'll try to figure out why this is
> systematic only on some architectures, does anyone have any ideas?
>
> Thanks,
> Stefano
prev parent reply other threads:[~2024-07-05 8:50 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-06-18 10:00 [PATCH v8 00/13] vhost-user: support any POSIX system (tested on macOS, FreeBSD, OpenBSD) Stefano Garzarella
2024-06-18 10:00 ` [PATCH v8 01/13] qapi: clarify that the default is backend dependent Stefano Garzarella
2024-06-18 10:34 ` Philippe Mathieu-Daudé
2024-06-18 10:00 ` [PATCH v8 02/13] libvhost-user: set msg.msg_control to NULL when it is empty Stefano Garzarella
2024-06-18 10:00 ` [PATCH v8 03/13] libvhost-user: fail vu_message_write() if sendmsg() is failing Stefano Garzarella
2024-06-18 10:00 ` [PATCH v8 04/13] libvhost-user: mask F_INFLIGHT_SHMFD if memfd is not supported Stefano Garzarella
2024-06-18 10:00 ` [PATCH v8 05/13] vhost-user-server: do not set memory fd non-blocking Stefano Garzarella
2024-06-18 10:04 ` [PATCH v8 06/13] contrib/vhost-user-blk: fix bind() using the right size of the address Stefano Garzarella
2024-06-18 10:04 ` [PATCH v8 07/13] contrib/vhost-user-*: use QEMU bswap helper functions Stefano Garzarella
2024-06-18 10:04 ` [PATCH v8 08/13] vhost-user: enable frontends on any POSIX system Stefano Garzarella
2024-06-18 10:05 ` [PATCH v8 09/13] libvhost-user: enable it " Stefano Garzarella
2024-06-18 10:05 ` [PATCH v8 10/13] contrib/vhost-user-blk: " Stefano Garzarella
2024-06-18 10:05 ` [PATCH v8 11/13] hostmem: add a new memory backend based on POSIX shm_open() Stefano Garzarella
2024-06-18 10:05 ` [PATCH v8 12/13] tests/qtest/vhost-user-blk-test: use memory-backend-shm Stefano Garzarella
2024-06-18 10:05 ` [PATCH v8 13/13] tests/qtest/vhost-user-test: add a test case for memory-backend-shm Stefano Garzarella
2024-07-03 22:49 ` [PATCH v8 00/13] vhost-user: support any POSIX system (tested on macOS, FreeBSD, OpenBSD) Michael S. Tsirkin
2024-07-05 8:39 ` Stefano Garzarella
2024-07-05 8:49 ` Michael S. Tsirkin [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20240705044754-mutt-send-email-mst@kernel.org \
--to=mst@redhat.com \
--cc=Coiby.Xu@gmail.com \
--cc=armbru@redhat.com \
--cc=berrange@redhat.com \
--cc=brad@comstyle.com \
--cc=david@redhat.com \
--cc=eblake@redhat.com \
--cc=eduardo@habkost.net \
--cc=gmaglione@redhat.com \
--cc=hreitz@redhat.com \
--cc=imammedo@redhat.com \
--cc=jasowang@redhat.com \
--cc=kraxel@redhat.com \
--cc=kwolf@redhat.com \
--cc=lvivier@redhat.com \
--cc=marcandre.lureau@redhat.com \
--cc=pbonzini@redhat.com \
--cc=philmd@linaro.org \
--cc=qemu-block@nongnu.org \
--cc=qemu-devel@nongnu.org \
--cc=raphael@enfabrica.net \
--cc=sgarzare@redhat.com \
--cc=slp@redhat.com \
--cc=stefanha@redhat.com \
--cc=thuth@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.