[PATCH 0/2] vhost-user: Remove the nested event loop to unbreak the DPDK use case

Greg Kurz posted 2 patches 1 year, 3 months ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/20230119172424.478268-1-groug@kaod.org
Maintainers: "Michael S. Tsirkin" <mst@redhat.com>
hw/virtio/vhost-user.c | 100 ++++-------------------------------------
1 file changed, 8 insertions(+), 92 deletions(-)
[PATCH 0/2] vhost-user: Remove the nested event loop to unbreak the DPDK use case
Posted by Greg Kurz 1 year, 3 months ago
The nested event loop was introduced in QEMU 6.0 to allow servicing
of requests coming from the slave channel while waiting for an ack
from the back-end on the master socket. It turns out this is fragile
and breaks if the servicing of the slave channel causes a new message
to be sent on the master socket. This is exactly what happens when
using DPDK as reported in [0].

The only identified user for the nested loop is DAX enablement that
isn't upstream yet. Just drop the code for now. Some more clever
solution should be designed when the need to service concurrent
requests from both channels arises again.

Greg Kurz (2):
  Revert "vhost-user: Monitor slave channel in vhost_user_read()"
  Revert "vhost-user: Introduce nested event loop in vhost_user_read()"

 hw/virtio/vhost-user.c | 100 ++++-------------------------------------
 1 file changed, 8 insertions(+), 92 deletions(-)

-- 
2.39.0

Re: [PATCH 0/2] vhost-user: Remove the nested event loop to unbreak the DPDK use case
Posted by Greg Kurz 1 year, 3 months ago
On Thu, 19 Jan 2023 18:24:22 +0100
Greg Kurz <groug@kaod.org> wrote:

> The nested event loop was introduced in QEMU 6.0 to allow servicing
> of requests coming from the slave channel while waiting for an ack
> from the back-end on the master socket. It turns out this is fragile
> and breaks if the servicing of the slave channel causes a new message
> to be sent on the master socket. This is exactly what happens when
> using DPDK as reported in [0].
> 
> The only identified user for the nested loop is DAX enablement that
> isn't upstream yet. Just drop the code for now. Some more clever
> solution should be designed when the need to service concurrent
> requests from both channels arises again.
> 
> Greg Kurz (2):
>   Revert "vhost-user: Monitor slave channel in vhost_user_read()"
>   Revert "vhost-user: Introduce nested event loop in vhost_user_read()"
> 
>  hw/virtio/vhost-user.c | 100 ++++-------------------------------------
>  1 file changed, 8 insertions(+), 92 deletions(-)
> 

Hi Michael,

Can you please merge this series as you kindly proposed in [0] ?
This will help to fix [1] which is currently blocking downstream
testing.

Cheers,

--
Greg

[0] https://lore.kernel.org/qemu-devel/20230118060102-mutt-send-email-mst@kernel.org/
[1] https://bugzilla.redhat.com/show_bug.cgi?id=2155173