doc: note a pitfall on reconnect feature
PATCH 1/1 doc: note a pitfall on reconnect feature
The vhost feature negotiation only happens at virtio reset stage, say when a virtio-net device is firstly initiated, or when DPDK virtio PMD initiates. That means, if vhost APP restarts after the negotiation and reconnects, the feature negotiation process will not be triggered again, meaning the info is lost. To make reconnect work, QEMU simply saves the negotiated features before the restart and restores it afterwards.
Therefore, the vhost supported features must be exactly the same before and after the restart. For example, if TSO is disabled and then enabled, nothing will work and issues undefined might happen.
---
I just put the part "people should not do this" into the doc, and I'm not quite sure I need put the "why" part there or not.
--- doc/guides/prog_guide/vhost_lib.rst | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-)
doc/guides/prog_guide/vhost_lib.rst +6 -1
@@ -189,7 +189,12 @@ vhost-user implementation has two options: When the DPDK vhost-user application restarts, DPDK vhost-user will try to connect to the server again. This is how the "reconnect" feature works. - Note: the "reconnect" feature requires **QEMU v2.7** (or above). + .. Note:: + * The "reconnect" feature requires **QEMU v2.7** (or above). + + * The vhost supported features must be exactly the same before and + after the restart. For example, if TSO is disabled and then enabled, + nothing will work and issues undefined might happen. No matter which mode is used, once a connection is established, DPDK vhost-user will start receiving and processing vhost messages from QEMU.
Signature · 1 line
1.9.0
RFC PATCH 1/1 maintainers: add git tree for virtio/vhost
Add a git tree line for the virtio/vhost section, to make an explicit statement that the developers are suggested to make patches based on that tree.
--- MAINTAINERS | 2 ++ 1 file changed, 2 insertions(+)
MAINTAINERS +2 -0
@@ -356,6 +356,7 @@ F: doc/guides/nics/qede.rst RedHat virtio M: Huawei Xie <[email protected]> M: Yuanhan Liu <[email protected]> +T: git://dpdk.org/next/dpdk-next-virtio F: drivers/net/virtio/ F: doc/guides/nics/virtio.rst F: lib/librte_vhost/
@@ -371,6 +372,7 @@ F: doc/guides/nics/vmxnet3.rst Vhost PMD M: Tetsuya Mukawa <[email protected]> M: Yuanhan Liu <[email protected]> +T: git://dpdk.org/next/dpdk-next-virtio F: drivers/net/vhost/ PCAP PMD
Signature · 1 line
1.9.0
Re: [PATCH RFC] maintainers: add git tree for virtio/vhost
2016-07-19 12:17, Yuanhan Liu:
Quoted 5 lines
Add a git tree line for the virtio/vhost section, to make an explicit statement that the developers are suggested to make patches based on that tree.
Signed-off-by Yuanhan Liu <[email protected]>
Applied, thanks for your work on next-virtio
Quoted 8 lines
doc/guides/prog_guide/vhost_lib.rst +5
-1- Note: the "reconnect" feature requires **QEMU v2.7** (or above). + .. Note:: + * The "reconnect" feature requires **QEMU v2.7** (or above). + + * The vhost supported features must be exactly the same before and + after the restart. For example, if TSO is disabled and thenenabled,
+ nothing will work and issues undefined might happen.
s/ issues undefined / undefined issues /
Apart from that:
Quoted 10 lines · John
Quoted 8 lines
doc/guides/prog_guide/vhost_lib.rst +5
-1- Note: the "reconnect" feature requires **QEMU v2.7** (or above). + .. Note:: + * The "reconnect" feature requires **QEMU v2.7** (or above). + + * The vhost supported features must be exactly the same before and + after the restart. For example, if TSO is disabled and thenenabled,
+ nothing will work and issues undefined might happen.s/ issues undefined / undefined issues /
Thomas, mind to fix it while apply?
Quoted 3 lines
Apart from that:
Acked-by John McNamara <[email protected]>
Thanks!
--yliu
Thomas Monjalon
Applied2016-07-20 09:08, Yuanhan Liu:
Quoted 10 lines · John
Quoted 9 lines
Quoted 8 lines
doc/guides/prog_guide/vhost_lib.rst +5
-1- Note: the "reconnect" feature requires **QEMU v2.7** (or above). + .. Note:: + * The "reconnect" feature requires **QEMU v2.7** (or above). + + * The vhost supported features must be exactly the same before and + after the restart. For example, if TSO is disabled and thenenabled,
+ nothing will work and issues undefined might happen.
Quoted 3 lines
Quoted 1 line
s/ issues undefined / undefined issues /
Thomas, mind to fix it while apply?
Yes
Quoted 5 lines
Quoted 3 lines
Apart from that:
Acked-by John McNamara <[email protected]>Thanks!
Applied, thanks