We allocate vring_spinlock for all vrings in the vui, not just the ones
being used. So when we free the vui, we have to free vring_spinlock for
all vrings, not just the one being used.
Type: fix
Signed-off-by: Steven Luong <sluong@cisco.com>
Change-Id: I3951fda71ce6e11474b04302116ea9e08b404758
vhost_user_update_gso_interface_count (vui, 0 /* delete */ );
vhost_user_update_iface_state (vui);
- FOR_ALL_VHOST_RX_TXQ (q, vui)
- {
+ for (q = 0; q < vec_len (vui->vrings); q++)
clib_spinlock_free (&vui->vrings[q].vring_lock);
- }
if (vui->unix_server_index != ~0)
{