From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) by dpdk.org (Postfix) with ESMTP id 1C7058DA9 for ; Fri, 6 Nov 2015 02:31:44 +0100 (CET) Received: from orsmga001.jf.intel.com ([10.7.209.18]) by orsmga101.jf.intel.com with ESMTP; 05 Nov 2015 17:31:45 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.20,249,1444719600"; d="scan'208";a="812931273" Received: from tan-s2600cw.sh.intel.com ([10.239.128.225]) by orsmga001.jf.intel.com with ESMTP; 05 Nov 2015 17:31:42 -0800 From: Jianfeng Tan To: dev@dpdk.org Date: Fri, 6 Nov 2015 02:31:16 +0800 Message-Id: <1446748276-132087-6-git-send-email-jianfeng.tan@intel.com> X-Mailer: git-send-email 2.1.4 In-Reply-To: <1446748276-132087-1-git-send-email-jianfeng.tan@intel.com> References: <1446748276-132087-1-git-send-email-jianfeng.tan@intel.com> Cc: nakajima.yoshihiro@lab.ntt.co.jp, zhbzg@huawei.com, mst@redhat.com, gaoxiaoqiu@huawei.com, oscar.zhangbo@huawei.com, ann.zhuangyanying@huawei.com, zhoujingbin@huawei.com, guohongzhen@huawei.com Subject: [dpdk-dev] [RFC 5/5] vhost/container: change mode of vhost listening socket X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 06 Nov 2015 01:31:45 -0000 Change vhost listening socket mode so that users in groups and others can connect to vhost listening socket. Signed-off-by: Huawei Xie Signed-off-by: Jianfeng Tan --- lib/librte_vhost/vhost_user/vhost-net-user.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lib/librte_vhost/vhost_user/vhost-net-user.c b/lib/librte_vhost/vhost_user/vhost-net-user.c index 2dc0547..7b24f7c 100644 --- a/lib/librte_vhost/vhost_user/vhost-net-user.c +++ b/lib/librte_vhost/vhost_user/vhost-net-user.c @@ -42,6 +42,7 @@ #include #include #include +#include #include #include @@ -137,6 +138,10 @@ uds_socket(const char *path) if (ret == -1) goto err; + ret = chmod(un.sun_path, 0666); + if (ret == 0) + RTE_LOG(INFO, VHOST_CONFIG, "chmod 0666, ok\n"); + return sockfd; err: -- 2.1.4