All of lore.kernel.org
 help / color / mirror / Atom feed
* [VHOST USER SPEC PATCH] vhost-user.rst: add clarifying language about protocol negotiation
@ 2021-02-26 11:16 ` Alex Bennée
  0 siblings, 0 replies; 11+ messages in thread
From: Alex Bennée @ 2021-02-26 11:16 UTC (permalink / raw)
  To: qemu-devel, rust-vmm
  Cc: virtio-dev, Michael S. Tsirkin, viresh.kumar, Jiang Liu,
	Alex Bennée, stratos-dev

In practice the protocol negotiation between vhost master and slave
occurs before the final feature negotiation between backend and
frontend. This has lead to an inconsistency between the rust-vmm vhost
implementation and the libvhost-user library in their approaches to
checking if all the requirements for REPLY_ACK processing were met.
As this is purely a function of the protocol negotiation and not of
interest to the frontend lets make the language clearer about the
requirements for a successfully negotiated protocol feature.

Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
Cc: Jiang Liu <gerry@linux.alibaba.com>
---
 docs/interop/vhost-user.rst | 14 ++++++++++++--
 1 file changed, 12 insertions(+), 2 deletions(-)

diff --git a/docs/interop/vhost-user.rst b/docs/interop/vhost-user.rst
index d6085f7045..3ac221a8c7 100644
--- a/docs/interop/vhost-user.rst
+++ b/docs/interop/vhost-user.rst
@@ -301,12 +301,22 @@ If *slave* detects some error such as incompatible features, it may also
 close the connection. This should only happen in exceptional circumstances.
 
 Any protocol extensions are gated by protocol feature bits, which
-allows full backwards compatibility on both master and slave.  As
-older slaves don't support negotiating protocol features, a feature
+allows full backwards compatibility on both master and slave. As older
+slaves don't support negotiating protocol features, a device feature
 bit was dedicated for this purpose::
 
   #define VHOST_USER_F_PROTOCOL_FEATURES 30
 
+However as the protocol negotiation something that only occurs between
+parts of the backend implementation it is permissible to for the master
+to mask the feature bit from the guest. As noted for the
+``VHOST_USER_GET_PROTOCOL_FEATURES`` and
+``VHOST_USER_SET_PROTOCOL_FEATURES`` messages this occurs before a
+final ``VHOST_USER_SET_FEATURES`` comes from the guest. So the
+enabling of protocol features need only require the advertising of the
+feature by the slave and the successful get/set protocol features
+sequence.
+  
 Starting and stopping rings
 ---------------------------
 
-- 
2.20.1



^ permalink raw reply related	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2021-03-01 17:20 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-02-26 11:16 [VHOST USER SPEC PATCH] vhost-user.rst: add clarifying language about protocol negotiation Alex Bennée
2021-02-26 11:16 ` [virtio-dev] " Alex Bennée
2021-02-26 11:21 ` no-reply
2021-03-01 11:05 ` [virtio-dev] " Stefan Hajnoczi
2021-03-01 11:05   ` Stefan Hajnoczi
2021-03-01 11:38   ` Alex Bennée
2021-03-01 11:38     ` Alex Bennée
2021-03-01 16:35     ` Stefan Hajnoczi
2021-03-01 16:35       ` Stefan Hajnoczi
2021-03-01 17:18       ` Michael S. Tsirkin
2021-03-01 17:18         ` Michael S. Tsirkin

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.