[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [virtio-dev] [RFC PATCH] docs/interop: define STANDALONE protocol fe
From: |
Michael S. Tsirkin |
Subject: |
Re: [virtio-dev] [RFC PATCH] docs/interop: define STANDALONE protocol feature for vhost-user |
Date: |
Wed, 26 Jul 2023 12:01:01 -0400 |
On Thu, Jul 20, 2023 at 03:36:01PM -0400, Stefan Hajnoczi wrote:
> On Fri, Jul 07, 2023 at 12:27:39PM +0200, Stefano Garzarella wrote:
> > On Tue, Jul 04, 2023 at 04:02:42PM +0100, Alex Bennée wrote:
> > >
> > > Stefano Garzarella <sgarzare@redhat.com> writes:
> > >
> > > > On Tue, Jul 04, 2023 at 01:36:00PM +0100, Alex Bennée wrote:
> > > > > diff --git a/docs/interop/vhost-user.rst b/docs/interop/vhost-user.rst
> > > > > index 5a070adbc1..85b1b1583a 100644
> > > > > --- a/docs/interop/vhost-user.rst
> > > > > +++ b/docs/interop/vhost-user.rst
> > > > > @@ -275,6 +275,21 @@ Inflight description
> > > > >
> > > > > :queue size: a 16-bit size of virtqueues
> > > > >
> > > > > +Backend specifications
> > > > > +^^^^^^^^^^^^^^^^^^^^^^
> > > > > +
> > > > > ++-----------+-------------+------------+------------+
> > > > > +| device id | config size | min_vqs | max_vqs |
> > > > > ++-----------+-------------+------------+------------+
> > > > > +
> > > > > +:device id: a 32-bit value holding the VirtIO device ID
> > > > > +
> > > > > +:config size: a 32-bit value holding the config size (see
> > > > > ``VHOST_USER_GET_CONFIG``)
> > > > > +
> > > > > +:min_vqs: a 32-bit value holding the minimum number of vqs supported
> > > >
> > > > Why do we need the minimum?
> > >
> > > We need to know the minimum number because some devices have fixed VQs
> > > that must be present.
> >
> > But does QEMU need to know this?
> >
> > Or is it okay that the driver will then fail in the guest if there
> > are not the right number of queues?
>
> I don't understand why min_vqs is needed either. It's not the
> front-end's job to ensure that the device will be used properly. A
> spec-compliant driver will work with a spec-compliant device, so it's
> not clear why the front-end needs this information.
>
> Stefan
I think this really demonstrates why we should keep separate
messages and not the "standalone" thing which seems to
mean "bundle a bunch of mostly unrelated stuff in one message":
this way each field is carefully documented.
--
MST
Re: [RFC PATCH] docs/interop: define STANDALONE protocol feature for vhost-user, Alex Bennée, 2023/07/06
Re: [RFC PATCH] docs/interop: define STANDALONE protocol feature for vhost-user, Michael S. Tsirkin, 2023/07/06
Re: [RFC PATCH] docs/interop: define STANDALONE protocol feature for vhost-user, Stefan Hajnoczi, 2023/07/20