From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by dpdk.org (Postfix) with ESMTP id 585167CFC for ; Fri, 25 Aug 2017 11:22:20 +0200 (CEST) Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 7E240883CA; Fri, 25 Aug 2017 09:22:19 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 7E240883CA Authentication-Results: ext-mx02.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx02.extmail.prod.ext.phx2.redhat.com; spf=fail smtp.mailfrom=jfreimann@redhat.com Received: from localhost (ovpn-117-66.ams2.redhat.com [10.36.117.66]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 5EABC7EA28; Fri, 25 Aug 2017 09:22:15 +0000 (UTC) Date: Fri, 25 Aug 2017 11:22:13 +0200 From: Jens Freimann To: Dariusz Stojaczyk Cc: dev@dpdk.org, Pawel Wodkowski , maxime.coquelin@redhat.com, yliu@fridaylinux.org Message-ID: <20170825092213.ce66eb2w56ui3iy2@localhost.localdomain> References: <1503308082-17926-1-git-send-email-dariuszx.stojaczyk@intel.com> <1503419092-63814-1-git-send-email-dariuszx.stojaczyk@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Disposition: inline In-Reply-To: <1503419092-63814-1-git-send-email-dariuszx.stojaczyk@intel.com> User-Agent: NeoMutt/20170714 (1.8.3) X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.26]); Fri, 25 Aug 2017 09:22:19 +0000 (UTC) Subject: Re: [dpdk-dev] [PATCH v2] vhost: added user callbacks for socket open/close X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Aug 2017 09:22:20 -0000 Hi Dariusz, On Tue, Aug 22, 2017 at 06:24:52PM +0200, Dariusz Stojaczyk wrote: >When user receives destroy_device signal, he does not know *why* that >event happened. He does not differ between socket shutdown and virtio >processing pause. User could completely delete device during transition >from BIOS to kernel, causing freeze or possibly kernel panic. Instead >of changing new_device/destroy_device callbacks and breaking the ABI, >a set of new functions new_connection/destroy_connection has been added. > >Signed-off-by: Dariusz Stojaczyk >--- >v2: also updated vhost_lib.rst > doc/guides/prog_guide/vhost_lib.rst | 15 +++++++++++++-- > lib/librte_vhost/rte_vhost.h | 5 ++++- > lib/librte_vhost/socket.c | 23 +++++++++++++++++++---- > 3 files changed, 36 insertions(+), 7 deletions(-) thanks for adding documentation! I'm still not sure I understand the use case. So just for my understanding: users need to distinct between "the device is going away temporarily, keep the connection" and "we're shutting down for good", is that it? Maybe it's just me or maybe it means you could explain your example in the commit message a bit more. I think the code looks sane, so Reviewed-by: Jens Freimann Oh, and you should put the maintainers on Cc to get a faster review. regards, Jens