Thanks for the fix, applied to master and branch-2.6



On 23/09/2016 06:17, "Ilya Maximets" <i.maxim...@samsung.com> wrote:

>'vhost_driver_flags' and 'vhost_id' are mutable and must be protected
>by 'dev->mutex'.
>
>Fixes: 2d24d165d6a5 ("netdev-dpdk: Add new 'dpdkvhostuserclient' port type")
>Signed-off-by: Ilya Maximets <i.maxim...@samsung.com>
>---
> lib/netdev-dpdk.c | 2 ++
> 1 file changed, 2 insertions(+)
>
>diff --git a/lib/netdev-dpdk.c b/lib/netdev-dpdk.c
>index 89bdc4d..ec43a08 100644
>--- a/lib/netdev-dpdk.c
>+++ b/lib/netdev-dpdk.c
>@@ -1116,6 +1116,7 @@ netdev_dpdk_vhost_client_set_config(struct netdev 
>*netdev,
>     struct netdev_dpdk *dev = netdev_dpdk_cast(netdev);
>     const char *path;
> 
>+    ovs_mutex_lock(&dev->mutex);
>     if (!(dev->vhost_driver_flags & RTE_VHOST_USER_CLIENT)) {
>         path = smap_get(args, "vhost-server-path");
>         if (path && strcmp(path, dev->vhost_id)) {
>@@ -1123,6 +1124,7 @@ netdev_dpdk_vhost_client_set_config(struct netdev 
>*netdev,
>             netdev_request_reconfigure(netdev);
>         }
>     }
>+    ovs_mutex_unlock(&dev->mutex);
> 
>     return 0;
> }
>-- 
>2.7.4
>
_______________________________________________
dev mailing list
dev@openvswitch.org
http://openvswitch.org/mailman/listinfo/dev

Reply via email to