From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by dpdk.org (Postfix) with ESMTP id 2A7873B5 for ; Fri, 17 Mar 2017 07:49:44 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=intel.com; i=@intel.com; q=dns/txt; s=intel; t=1489733385; x=1521269385; h=date:from:to:cc:subject:message-id:references: mime-version:in-reply-to; bh=M9I6qAEYZuKtI8blGZMX1+GKzeojYcXOzQfSoy3TEm0=; b=oeDsPkd97cjyUb/RcjIQk8wQlyZrACStYAPTBvcJkydaWPSNqgaDIMVD hQModsI0H5sX8EfFCp8pxLTelLbqRg==; Received: from orsmga004.jf.intel.com ([10.7.209.38]) by orsmga102.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 16 Mar 2017 23:49:43 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.36,175,1486454400"; d="scan'208";a="68278939" Received: from yliu-dev.sh.intel.com (HELO yliu-dev) ([10.239.67.162]) by orsmga004.jf.intel.com with ESMTP; 16 Mar 2017 23:49:43 -0700 Date: Fri, 17 Mar 2017 14:47:57 +0800 From: Yuanhan Liu To: Jianfeng Tan Cc: dev@dpdk.org, david.marchand@6wind.com Message-ID: <20170317064757.GG18844@yliu-dev.sh.intel.com> References: <1488563803-87754-1-git-send-email-jianfeng.tan@intel.com> <1488563803-87754-3-git-send-email-jianfeng.tan@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1488563803-87754-3-git-send-email-jianfeng.tan@intel.com> User-Agent: Mutt/1.5.23 (2014-03-12) Subject: Re: [dpdk-dev] [PATCH 2/5] net/virtio-user: add rxq interrupt mode support 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, 17 Mar 2017 06:49:45 -0000 On Fri, Mar 03, 2017 at 05:56:40PM +0000, Jianfeng Tan wrote: > Signed-off-by: Jianfeng Tan I don't see a single word to explain how this patch works :/ > --- > drivers/net/virtio/virtio_ethdev.c | 17 ++++++++++++++-- > drivers/net/virtio/virtio_user/virtio_user_dev.c | 25 +++++++++++++++++++++++- > drivers/net/virtio/virtio_user/virtio_user_dev.h | 2 +- > drivers/net/virtio/virtio_user_ethdev.c | 12 +++++++++++- > 4 files changed, 51 insertions(+), 5 deletions(-) > > diff --git a/drivers/net/virtio/virtio_ethdev.c b/drivers/net/virtio/virtio_ethdev.c > index 4dc03b9..5d80d1a 100644 > --- a/drivers/net/virtio/virtio_ethdev.c > +++ b/drivers/net/virtio/virtio_ethdev.c > @@ -1264,6 +1264,10 @@ virtio_configure_intr(struct rte_eth_dev *dev) > { > struct virtio_hw *hw = dev->data->dev_private; > > + > +#ifdef RTE_VIRTIO_USER > + if (!hw->virtio_user_dev) { > +#endif No need to put the #ifdef block here. virtio_user_dev is defined even when RTE_VIRTIO_USER is not configured. ... > + vtpci_reinit_complete(hw); > + > if (eth_dev->data->dev_conf.intr_conf.rxq) { > if (virtio_configure_intr(eth_dev) < 0) { > PMD_INIT_LOG(ERR, "failed to configure interrupt"); > @@ -1416,8 +1431,6 @@ virtio_init_device(struct rte_eth_dev *eth_dev, uint64_t req_features) > } > } > > - vtpci_reinit_complete(hw); Hmm, why ...? Such stealthy change definitely need an explanation. And it's more likely it needs a single patch. --yliu