vhost: fix shadow update
vhost: fix shadow update

Defer shadow ring update introduces functional issue which has been
described in Eugenio's fix patch.

The current implementation of vhost_net in packed vring tries to fill
the shadow vector before send any actual changes to the guest. While
this can be beneficial for the throughput, it conflicts with some
bufferfloats methods like the linux kernel napi, that stops
transmitting packets if there are too much bytes/buffers in the
driver.

It also introduces performance issue when frontend run much faster than
backend. Frontend may not be able to collect available descs when shadow
update is deferred. That will harm RFC2544 throughput.

Appropriate choice is to remove deferred shadowed update method.
Now shadowed used descs are flushed at the end of dequeue function.

Fixes: 31d6c6a5b820 ("vhost: optimize packed ring dequeue")
Cc: stable@dpdk.org

Signed-off-by: Marvin Liu <d89ea4150d91f674af88bbc382d184dd42ea906c@intel.com>
Tested-by: Yinan Wang <49b1c4c1483798ccfe23a5285410aaacc037c97a@intel.com>
Reviewed-by: Maxime Coquelin <9a2667dee3b90866bbc9c2696cff2b7d5616c95a@redhat.com>

john-mcnamara-intel/dpdk,john-mcnamara-intel/dpdk,john-mcnamara-intel/dpdk,john-mcnamara-intel/dpdk