From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pa0-f52.google.com (mail-pa0-f52.google.com [209.85.220.52]) by dpdk.org (Postfix) with ESMTP id 5414E374E for ; Tue, 24 Nov 2015 05:42:51 +0100 (CET) Received: by pacdm15 with SMTP id dm15so8435738pac.3 for ; Mon, 23 Nov 2015 20:42:50 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=igel-co-jp.20150623.gappssmtp.com; s=20150623; h=subject:to:references:cc:from:message-id:date:user-agent :mime-version:in-reply-to:content-type:content-transfer-encoding; bh=HNMPzkqKVPxjNgZ/M4aK2NtohzWMz1lllkYCOyv9IWA=; b=ql9hcjH4YMxSY9gAQ/REnLjdpHqJbbKOX08SVyhhF8+8okzxg9lY8nQLb35gve9BVm Im/uZ9OU8UkvwNZrOOtTSiTypyBIco6v65VTmocg9BLoW+2xPOABhzgIFFQXFKvAPKWJ mXTwlG3wh4pN0b0Pz1ObBCZagH6DX+oLNec2MpcVtT2mvTisCVHh5ysA7aX/YoI15kpG heVi+yqoBlJowAuZ7AQ6LbWSYH0BwBUBXPci7GdYMXGXD+itN3IG419t2quKSurOdmtv iy8uCNhkE0ZR3/ZOwRCwv4fFio5WVeaQy0EPNpF+8C7cuMgKNOwaOVt65uuijP+/C39w ymTw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:subject:to:references:cc:from:message-id:date :user-agent:mime-version:in-reply-to:content-type :content-transfer-encoding; bh=HNMPzkqKVPxjNgZ/M4aK2NtohzWMz1lllkYCOyv9IWA=; b=OCF6rYYdix0N8JDpov/Gbi1nBIRd5c8En5+oxzuHTI7csIzBIQo5qZhUsKEnwn3psI 9lLysWxCFad6h0eh8vVhESn6ohaeumMTmqgvGhBF+Wc1lry+RDIsEZhyo2rtK6Mh6iFe hpQahKIpQsqXvneCZHv8UwILEM4vmbaxbada5m1+DaXEmZD60p34KsyYOM9QMXAtUXeH o+PM9R80ub8BUDXwlJTgtnrcSyOHv+QMwDkM5Q6aQIaGKGaDtCfENTjORAZtBg1o/nKe jxj5BGDh7Bir/0GSdhMQ4/s7+lT6Bdn5YVwWslgwYWLDLTcZSDZDJcaJf5UuEPXCFqNg 8oHQ== X-Gm-Message-State: ALoCoQnsRf6zX9qlklcRp8wQaDPg1OYJVV2VrAS2uzYcDHy4+Epj1NajephTS7UQglP9YVykWw7z X-Received: by 10.66.199.5 with SMTP id jg5mr40317172pac.72.1448340170760; Mon, 23 Nov 2015 20:42:50 -0800 (PST) Received: from [10.16.129.101] (napt.igel.co.jp. [219.106.231.132]) by smtp.googlemail.com with ESMTPSA id ga13sm12384717pac.47.2015.11.23.20.42.49 (version=TLSv1/SSLv3 cipher=OTHER); Mon, 23 Nov 2015 20:42:50 -0800 (PST) To: Yuanhan Liu References: <1447914206-18369-1-git-send-email-mukawa@igel.co.jp> <1447924020-26894-1-git-send-email-mukawa@igel.co.jp> <20151120112125.GA2325@yliu-dev.sh.intel.com> From: Tetsuya Mukawa Message-ID: <5653EAC9.80704@igel.co.jp> Date: Tue, 24 Nov 2015 13:42:49 +0900 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:38.0) Gecko/20100101 Thunderbird/38.3.0 MIME-Version: 1.0 In-Reply-To: <20151120112125.GA2325@yliu-dev.sh.intel.com> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Cc: dev@dpdk.org, ann.zhuangyanying@huawei.com Subject: Re: [dpdk-dev] [PATCH v2] vhost: Fix reset_owner message handling not to clear callfd 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: Tue, 24 Nov 2015 04:42:51 -0000 On 2015/11/20 20:21, Yuanhan Liu wrote: > On Thu, Nov 19, 2015 at 06:07:00PM +0900, Tetsuya Mukawa wrote: >> The patch fixes reset_owner message handling not to clear callfd, >> because callfd will be valid while connection is establihed. >> >> Signed-off-by: Tetsuya Mukawa > .... >> >> /* >> @@ -467,6 +486,7 @@ static int >> reset_owner(struct vhost_device_ctx ctx) >> { >> struct virtio_net *dev; >> + uint32_t i; >> >> dev = get_device(ctx); >> if (dev == NULL) >> @@ -475,7 +495,19 @@ reset_owner(struct vhost_device_ctx ctx) >> if (dev->flags & VIRTIO_DEV_RUNNING) >> notify_destroy_device(dev); >> >> - cleanup_device(dev); > I would suggest to introduce the destory flag to cleanup_device() as > well, so that we don't have to unfold the cleanup_device code here. > > (BTW, I should've reviewed this patch this morning, but I was busy). Thanks, I will submit it again. Tetsuya