From mboxrd@z Thu Jan 1 00:00:00 1970 From: Yuanhan Liu Subject: Re: [PATCH v2 1/3] net/virtio_user: fix queue pair not enabled Date: Wed, 28 Sep 2016 08:05:12 +0800 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 Cc: dev@dpdk.org, stable@dpdk.org To: Jianfeng Tan Return-path: Content-Disposition: inline In-Reply-To: <1475003466-146063-2-git-send-email-jianfeng.tan@intel.com> List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" 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