From mboxrd@z Thu Jan 1 00:00:00 1970 From: Maxime Coquelin Subject: Re: [PATCH] vhost: refine the vhost_new_device Date: Fri, 15 Jun 2018 10:01:59 +0200 Message-ID: <1d23b8f9-f5b5-b344-0052-93690973df7e@redhat.com> References: <1528449484-8664-1-git-send-email-xiangxia.m.yue@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit To: xiangxia.m.yue@gmail.com, dev@dpdk.org Return-path: Received: from mx1.redhat.com (mx3-rdu2.redhat.com [66.187.233.73]) by dpdk.org (Postfix) with ESMTP id 71BE01D92E for ; Fri, 15 Jun 2018 10:02:01 +0200 (CEST) In-Reply-To: <1528449484-8664-1-git-send-email-xiangxia.m.yue@gmail.com> Content-Language: en-US List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On 06/08/2018 11:18 AM, xiangxia.m.yue@gmail.com wrote: > From: Tonghao Zhang > > Make sure find avalid device id before allocating > virtio_net, if not, return directly. It may avoid > allocating and freeing virtio_net when there is > not valid device id. > > Signed-off-by: Tonghao Zhang > --- > lib/librte_vhost/vhost.c | 16 ++++++++-------- > 1 file changed, 8 insertions(+), 8 deletions(-) Applied to dpdk-next-virtio/master Thanks, Maxime