virtio-devices: vhost-user: Fix device reset

There is no need to get the vring base when resetting the vhost-user
device. This was mostly ignored, but in some cases, it was causing some
actual errors.

A reset must simply be a combination of disabling the vrings along with
the reset of the owner.

Signed-off-by: Sebastien Boeuf <sebastien.boeuf@intel.com>
This commit is contained in:
Sebastien Boeuf 2021-03-08 18:12:29 +01:00
parent 16b82f3dfe
commit 581bf4aad5

View File

@ -135,10 +135,6 @@ pub fn reset_vhost_user(vu: &mut Master, num_queues: usize) -> Result<()> {
// Disable the vrings.
vu.set_vring_enable(queue_index, false)
.map_err(Error::VhostUserSetVringEnable)?;
// Stop the vrings.
vu.get_vring_base(queue_index)
.map_err(Error::VhostUserSetFeatures)?;
}
// Reset the owner.