diff options
author | Pierre Pfister <ppfister@cisco.com> | 2016-11-21 12:50:38 +0000 |
---|---|---|
committer | Damjan Marion <dmarion.lists@gmail.com> | 2016-11-24 09:34:56 +0000 |
commit | 7a91b46e03f8d67d2669050fdb890ef11c31de79 (patch) | |
tree | 2bf28e7edfe84435b9fec961d8a802b3d9da3a6f | |
parent | c5bf07fabe46c175890bb5661a85ed076fbf7f2d (diff) |
vhost: Delete thread configuration when interface deleted
It does not make sense to keep interface configuration
when a vhost interface is deleted.
This fix makes sure thread configuration is removed.
Change-Id: I4b3b75d98c15b544c32928f79ef52b7622a86b75
Signed-off-by: Pierre Pfister <ppfister@cisco.com>
-rw-r--r-- | vnet/vnet/devices/virtio/vhost-user.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/vnet/vnet/devices/virtio/vhost-user.c b/vnet/vnet/devices/virtio/vhost-user.c index 6a7f7e600ba..decfebba1c3 100644 --- a/vnet/vnet/devices/virtio/vhost-user.c +++ b/vnet/vnet/devices/virtio/vhost-user.c @@ -2205,6 +2205,8 @@ vhost_user_delete_if (vnet_main_t * vnm, vlib_main_t * vm, u32 sw_if_index) // interface is inactive vui->active = 0; + // Delete configured thread pinning + vec_reset_length (vui->workers); // disconnect interface sockets vhost_user_if_disconnect (vui); vhost_user_update_iface_state (vui); |