From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga07.intel.com (mga07.intel.com [134.134.136.100]) by dpdk.org (Postfix) with ESMTP id 7FF4437B4; Wed, 28 Sep 2016 02:04:38 +0200 (CEST) Received: from orsmga004.jf.intel.com ([10.7.209.38]) by orsmga105.jf.intel.com with ESMTP; 27 Sep 2016 17:04:37 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.30,407,1470726000"; d="scan'208";a="14413497" Received: from yliu-dev.sh.intel.com (HELO yliu-dev) ([10.239.67.162]) by orsmga004.jf.intel.com with ESMTP; 27 Sep 2016 17:04:36 -0700 Date: Wed, 28 Sep 2016 08:05:12 +0800 From: Yuanhan Liu To: Jianfeng Tan Cc: dev@dpdk.org, stable@dpdk.org Message-ID: <20160928000512.GA1597@yliu-dev.sh.intel.com> References: <1470397003-5782-1-git-send-email-jianfeng.tan@intel.com> <1475003466-146063-1-git-send-email-jianfeng.tan@intel.com> <1475003466-146063-2-git-send-email-jianfeng.tan@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1475003466-146063-2-git-send-email-jianfeng.tan@intel.com> User-Agent: Mutt/1.5.23 (2014-03-12) Subject: Re: [dpdk-dev] [PATCH v2 1/3] net/virtio_user: fix queue pair not enabled 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: Wed, 28 Sep 2016 00:04:39 -0000 On Tue, Sep 27, 2016 at 07:11:04PM +0000, Jianfeng Tan wrote: > When virtio_user is used with OVS-DPDK (with mq disabled), it cannot > receive any packets. > > It's because when vhost provides VHOST_USER_GET_PROTOCOL_FEATURES, > all queue pairs are initialized in the disabled state. Quote > QEMU/docs/specs/vhost-user.txt: > If VHOST_USER_F_PROTOCOL_FEATURES has not been negotiated, the > ring is initialized in an enabled state. > If VHOST_USER_F_PROTOCOL_FEATURES has been negotiated, the ring > is initialized in a disabled state. As stated before, it has nothing to do with VHOST_USER_F_PROTOCOL_FEATURES. You seems forgot to change the commit log. > > In OVS-DPDK, all queue pairs are in the disabled state by default. > When used with QEMU, QEMU will set it as enabled in the process of > initialization. So this patch is to add similar logic in virtio_user. I would reword the commit log to someting like following: When virtio_user is used with OVS-DPDK (with mq disabled), it cannot receive any packets. This is because no queue is enabled at all when mq is disabled. To fix it, we should consistently make sure the 1st queue is enabled,which is also the behaviour QEMU takes. > Fixes: 37a7eb2ae816 ("net/virtio-user: add device emulation layer") > > Reported-by: Ning Li > Signed-off-by: Jianfeng Tan Series applied to dpdk-next-virtio, with above commit reword. Thanks. --yliu