[ovs-dev] [PATCH v2] netdev-dpdk: Clean-up after vHost User port delete

Daniele Di Proietto diproiettod at vmware.com
Thu Oct 22 19:49:20 UTC 2015


I applied this to master, thanks

On 21/10/2015 06:50, "Ciara Loftus" <ciara.loftus at intel.com> wrote:

>Unregister and delete the socket associated with a vhost-user
>port when the port is deleted and/or the switch is brought down.
>Do not delete the socket if the vhost-user device is still attached
>to the guest.
>
>Signed-off-by: Ciara Loftus <ciara.loftus at intel.com>
>---
> lib/netdev-dpdk.c | 4 ++++
> 1 file changed, 4 insertions(+)
>
>diff --git a/lib/netdev-dpdk.c b/lib/netdev-dpdk.c
>index 93b0589..f0f3cda 100644
>--- a/lib/netdev-dpdk.c
>+++ b/lib/netdev-dpdk.c
>@@ -749,6 +749,10 @@ netdev_dpdk_vhost_destruct(struct netdev *netdev_)
>                 return;
>     }
> 
>+    if (rte_vhost_driver_unregister(dev->vhost_id)) {
>+        VLOG_ERR("Unable to remove vhost-user socket %s", dev->vhost_id);
>+    }
>+
>     ovs_mutex_lock(&dpdk_mutex);
>     list_remove(&dev->list_node);
>     dpdk_mp_put(dev->dpdk_mp);
>-- 
>1.9.3
>
>_______________________________________________
>dev mailing list
>dev at openvswitch.org
>https://urldefense.proofpoint.com/v2/url?u=http-3A__openvswitch.org_mailma
>n_listinfo_dev&d=BQIGaQ&c=Sqcl0Ez6M0X8aeM67LKIiDJAXVeAw-YihVMNtXt-uEs&r=Sm
>B5nZacmXNq0gKCC1s_Cw5yUNjxgD4v5kJqZ2uWLlE&m=5dubWRleZ-YLCcyJR2a6e06vRuJP_3
>TqENxmWypNna4&s=bkVqfxE4qptVzfeLcthZIkqAvo-b2hX5RQINTWjnRbU&e= 




More information about the dev mailing list