From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from out3-smtp.messagingengine.com (out3-smtp.messagingengine.com [66.111.4.27]) by dpdk.org (Postfix) with ESMTP id 6136C1B2C2 for ; Fri, 26 Jan 2018 14:05:01 +0100 (CET) Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id 24F2F20C89; Fri, 26 Jan 2018 08:05:00 -0500 (EST) Received: from frontend1 ([10.202.2.160]) by compute1.internal (MEProxy); Fri, 26 Jan 2018 08:05:01 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fridaylinux.org; h=cc:content-type:date:from:in-reply-to:message-id:mime-version :references:subject:to:x-me-sender:x-me-sender:x-sasl-enc; s= fm1; bh=EVn/3BAcA4se8UAoLftM1wqeW1kIxoeUq02tVYBZ4A4=; b=ZtDo4FdU ZpyjWnUoMFvs1dnr7OD6CgJdyrimOkXJFK/lsmVk5Z6hK0e4bSuEzZJhMrWsMFnU KWnUKhzQAA9qgaAxgA/9GpOItj+qlrDm9s5cDXXh1pRCe35VuhVZNyfq52irprNu +AVjfnTARbn9nhOVbnPhi/d9rc8yE1bVya1DXPcekgd8vQ+KMTA6wD0ZZm6Ykomj 68XGOw5x7APJ0JnWyoV20RMw00ezQW/ROnwyFwNwc3m6UiRvvTn2c1o9Nz/UPT8v x1+RkDsyvAjG5bBxKU3/oQg9Tzr6YkUmRuDp20jKz+9ocJtpQzFJbCeEI+vZt1s/ vOwYX28AEbfTxQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-sender :x-me-sender:x-sasl-enc; s=fm1; bh=EVn/3BAcA4se8UAoLftM1wqeW1kIx oeUq02tVYBZ4A4=; b=HFPZQAyUUTIkBYm2pnO2NxgJAyiQJXr92oPycbkCQFp1U s+XCaFyEoFNbiPpiIj8ibHu9hkND1LlByqd3nckvXscBNE+/5guWzZccoh7OosPE APxzoTXHCFZ6Owhz7t5ISm1/PyxotiwSzW99+xBkFjR4Qhl2oW3VmVKf5An6ILVl R+Iz/lRMjPjJxs+8MBsoF3hqhMQ70Gp++YiVfQwuyQmfPLjYS/kD932ZpTpq2num ZepRTtwhMqWrae2sMYwCciY9MsmjJ1wWZH1kYV01JdwSDjo+cGpyXYP8edU6HBl8 gtmmIZTOs6fmoXaemwjBymrvEdhW6M30eLIevQhSQ== X-ME-Sender: Received: from yliu-mob (unknown [182.84.185.39]) by mail.messagingengine.com (Postfix) with ESMTPA id E14A47E0FD; Fri, 26 Jan 2018 08:04:59 -0500 (EST) Date: Fri, 26 Jan 2018 21:04:55 +0800 From: Yuanhan Liu To: "Tan, Jianfeng" Cc: Zhihong Wang , dev@dpdk.org Message-ID: <20180126130455.GC29540@yliu-mob> References: <1516388570-42634-1-git-send-email-zhihong.wang@intel.com> <20180119144254.GQ29540@yliu-mob> <6637c690-e659-ef2f-a077-d2a8e5f8b120@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <6637c690-e659-ef2f-a077-d2a8e5f8b120@intel.com> User-Agent: Mutt/1.5.24 (2015-08-30) Subject: Re: [dpdk-dev] [PATCH] vhost: fix ANY_LAYOUT declaration 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, 26 Jan 2018 13:05:02 -0000 On Sat, Jan 20, 2018 at 01:54:52AM +0800, Tan, Jianfeng wrote: > > > On 1/19/2018 10:42 PM, Yuanhan Liu wrote: > >On Fri, Jan 19, 2018 at 02:02:50PM -0500, Zhihong Wang wrote: > >>The VIRTIO_F_ANY_LAYOUT feature indicates the device accepts arbitrary > >>descriptor layouts. The vhost-user lib already supports it, but the > >>feature declaration is missing. This patch fixes the mismatch. > >I remembered there was a long discussion one year ago, that we can't > >blindly set this feature, as this flag is reserved (thus should not > >be set) for virtio 1.0. > > We might need to read that old thread again. But as you said, this flag is > reserved for 1.0, but not used for other purpose yet. So that the feature is > negotiated does not affect anything, no? > > > > >We should set it when v1.0 is not enabled. > > But in fact, vhost kernel reports supported feature bits consisting of > ANY_LAYOUT and VERSION_1. Yes, I was aware of that, and that was also one my points before. I now also release that it's a must from migration from vhost-net to vhost-user. Thus, I'd like to merge it this time. So Applied to dpdk-next-virtio. Thanks. --yliu > > > However, as you know, v1.0 is also enabled by default in DPDK vhost-user. > > Even v1.0 is used, the feature negotiated between virtio-net (kernel) and > vhost kernel indeed contains ANY_LAYOUT. I suppose we shall do as the > de-facto way. > > Thanks, > Jianfeng > > > > > --yliu > >>Signed-off-by: Zhihong Wang > >>--- > >> lib/librte_vhost/vhost.h | 1 + > >> 1 file changed, 1 insertion(+) > >> > >>diff --git a/lib/librte_vhost/vhost.h b/lib/librte_vhost/vhost.h > >>index b2bf0e8..57a9bea 100644 > >>--- a/lib/librte_vhost/vhost.h > >>+++ b/lib/librte_vhost/vhost.h > >>@@ -170,6 +170,7 @@ struct vhost_msg { > >> /* Features supported by this builtin vhost-user net driver. */ > >> #define VIRTIO_NET_SUPPORTED_FEATURES ((1ULL << VIRTIO_NET_F_MRG_RXBUF) | \ > >>+ (1ULL << VIRTIO_F_ANY_LAYOUT) | \ > >> (1ULL << VIRTIO_NET_F_CTRL_VQ) | \ > >> (1ULL << VIRTIO_NET_F_CTRL_RX) | \ > >> (1ULL << VIRTIO_NET_F_GUEST_ANNOUNCE) | \ > >>-- > >>2.7.5