Re: [PATCH v7] virtio-vsock: Add support for multi devices

Xuewei Niu <[email protected]>
Newsgroups dev.linux.lists.virtio-comment
Message-ID <[email protected]>
> On Fri, 13 Jun 2025 at 06:23, Jason Wang <[email protected]> wrote:
> >
> > On Sat, Apr 12, 2025 at 10:39 PM Xuewei Niu <[email protected]> wrote:
> > >
> > > This patch brings a new feature, called "multi devices", to the virtio
> > > vsock. It introduces a "VIRTIO_VSOCK_F_MULTI_DEVICES" feature bit, and a
> > > "device_order" field to the config for the virtio vsock.
> > >
> > > == Motivition ==
> > >
> > > Vsock is a lightweight and widely used data exchange mechanism between host
> > > and guest. Currently, the virtio-vsock only supports one device, resulting
> > > in the inability to enable more than one backend.
> >
> > I wonder which part of the spec forbids more than one device.
> 
> I don't think there isn't anything that forbid it, but what we don't
> have is a kind of default gateway/interface to use when sending
> messages.
> So, this proposal is mostly to chose the default device to use, when
> the user don't bind any CID on the source socket.
> 
> >
> > > For instance, two devices
> > > are required: one to transfer data to the VMM via virtio-vsock, and another
> > > to a user process via vhost-user-vsock.
> > >
> > > Apart from that, a side gain is that theoretically the performance might be
> > > improved since each device has its own queue. But it varies depending on
> > > the implementation.
> >
> > It could implement multiqueue anyhow.
> 
> Yeah, I pointed out multiple times to skip this as justification,
> since multi-queue has more much sense for that.
> IMHO it's confusing to still talk about it in this proposal.
> 
> Stefano
> 
> >
> > Thanks
> >

Thanks for the clarification. I'll remove such descriptions in the next
version.

Thanks,
Xuewei
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.