From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 1EAACA09E4; Thu, 28 Jan 2021 15:07:34 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 370B540683; Thu, 28 Jan 2021 15:07:33 +0100 (CET) Received: from mga07.intel.com (mga07.intel.com [134.134.136.100]) by mails.dpdk.org (Postfix) with ESMTP id 3548F4067A; Thu, 28 Jan 2021 15:07:30 +0100 (CET) IronPort-SDR: ncyPVyiVHos1sU3noElwGSvr5qdzYxZDJeIp2sEcEfrTVa4e9RdilviWX94Gvkly8NfelaAgK/ cOmlCPG3/YnQ== X-IronPort-AV: E=McAfee;i="6000,8403,9877"; a="244322883" X-IronPort-AV: E=Sophos;i="5.79,382,1602572400"; d="scan'208";a="244322883" Received: from orsmga001.jf.intel.com ([10.7.209.18]) by orsmga105.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 28 Jan 2021 06:07:07 -0800 IronPort-SDR: K7iLifdXAh/OZhzYsLeBVW7W7EVsRsUQU8fp6Nd2nJzQfVjSrYm2XAxVJ7+l/ZsRNnodONpII6 2RX/t9T6k3GA== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.79,382,1602572400"; d="scan'208";a="430519901" Received: from fmsmsx606.amr.corp.intel.com ([10.18.126.86]) by orsmga001.jf.intel.com with ESMTP; 28 Jan 2021 06:07:07 -0800 Received: from shsmsx605.ccr.corp.intel.com (10.109.6.215) by fmsmsx606.amr.corp.intel.com (10.18.126.86) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2106.2; Thu, 28 Jan 2021 06:07:07 -0800 Received: from shsmsx601.ccr.corp.intel.com (10.109.6.141) by SHSMSX605.ccr.corp.intel.com (10.109.6.215) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.1713.5; Thu, 28 Jan 2021 22:07:05 +0800 Received: from shsmsx601.ccr.corp.intel.com ([10.109.6.141]) by SHSMSX601.ccr.corp.intel.com ([10.109.6.141]) with mapi id 15.01.1713.004; Thu, 28 Jan 2021 22:07:05 +0800 From: "Zhang, Qi Z" To: "Xing, Beilei" , "Wu, Jingjing" , "dev@dpdk.org" CC: "stable@dpdk.org" Thread-Topic: [PATCH] net/iavf: fix vector mapping with queue Thread-Index: AQHW9SZYabK1ok3syUCy6IbrFOF9O6o9EkmQ Date: Thu, 28 Jan 2021 14:07:04 +0000 Message-ID: <050a675000fa4cb9af6ee593bb6af942@intel.com> References: <20210128023724.39057-1-jingjing.wu@intel.com> In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-reaction: no-action dlp-version: 11.5.1.3 dlp-product: dlpe-windows x-originating-ip: [10.239.127.36] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: Re: [dpdk-dev] [PATCH] net/iavf: fix vector mapping with queue X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" > -----Original Message----- > From: dev On Behalf Of Xing, Beilei > Sent: Thursday, January 28, 2021 11:32 AM > To: Wu, Jingjing ; dev@dpdk.org > Cc: stable@dpdk.org > Subject: Re: [dpdk-dev] [PATCH] net/iavf: fix vector mapping with queue >=20 >=20 >=20 > > -----Original Message----- > > From: Wu, Jingjing > > Sent: Thursday, January 28, 2021 10:37 AM > > To: dev@dpdk.org > > Cc: Wu, Jingjing ; Xing, Beilei > > ; stable@dpdk.org > > Subject: [PATCH] net/iavf: fix vector mapping with queue > > > > Fix the vector mapping with queue by changing the recircle when > > exceeds RX_VEC_START + nb_msix; > > > > Fixes: d6bde6b5eae9 ("net/avf: enable Rx interrupt") > > > > Signed-off-by: Jingjing Wu > > --- > > drivers/net/iavf/iavf_ethdev.c | 4 ++-- > > 1 file changed, 2 insertions(+), 2 deletions(-) > > > > diff --git a/drivers/net/iavf/iavf_ethdev.c > > b/drivers/net/iavf/iavf_ethdev.c index cf6ea0b15..eb800771d 100644 > > --- a/drivers/net/iavf/iavf_ethdev.c > > +++ b/drivers/net/iavf/iavf_ethdev.c > > @@ -612,7 +612,7 @@ static int iavf_config_rx_queues_irqs(struct > > rte_eth_dev *dev, > > /* If Rx interrupt is reuquired, and we can use > > * multi interrupts, then the vec is from 1 > > */ > > - vf->nb_msix =3D RTE_MIN(vf->vf_res->max_vectors, > > + vf->nb_msix =3D RTE_MIN(vf->vf_res->max_vectors - 1, > > intr_handle->nb_efd); > > vf->msix_base =3D IAVF_RX_VEC_START; > > vec =3D IAVF_RX_VEC_START; > > @@ -620,7 +620,7 @@ static int iavf_config_rx_queues_irqs(struct > > rte_eth_dev *dev, > > qv_map[i].queue_id =3D i; > > qv_map[i].vector_id =3D vec; > > intr_handle->intr_vec[i] =3D vec++; > > - if (vec >=3D vf->nb_msix) > > + if (vec >=3D vf->nb_msix + IAVF_RX_VEC_START) > > vec =3D IAVF_RX_VEC_START; > > } > > vf->qv_map =3D qv_map; > > -- > > 2.21.1 >=20 > Acked-by: Beilei Xing The patch has some compile warning need to be fixed. [1/23] Compiling C object drivers/libtmp_rte_net_iavf.a.p/net_iavf_iavf_eth= dev.c.o In file included from ../lib/librte_eal/x86/include/rte_byteorder.h:13, from ../drivers/net/iavf/iavf_ethdev.c:13: ../drivers/net/iavf/iavf_ethdev.c: In function 'iavf_config_rx_queues_irqs'= : ../lib/librte_eal/include/rte_common.h:577:6: warning: comparison of intege= r expressions of different signedness: 'int' and 'uint32_t' {aka 'unsigned = int'} [-Wsign-compare] 577 | _a < _b ? _a : _b; \ | ^ ../drivers/net/iavf/iavf_ethdev.c:613:18: note: in expansion of macro 'RTE_= MIN' 613 | vf->nb_msix =3D RTE_MIN(vf->vf_res->max_vectors - 1, | ^~~~~~~ ../lib/librte_eal/include/rte_common.h:577:13: warning: operand of '?:' cha= nges signedness from 'int' to 'uint32_t' {aka 'unsigned int'} due to unsign= edness of other operand [-Wsign-compare] 577 | _a < _b ? _a : _b; \ | ^~ ../drivers/net/iavf/iavf_ethdev.c:613:18: note: in expansion of macro 'RTE_= MIN' 613 | vf->nb_msix =3D RTE_MIN(vf->vf_res->max_vectors - 1, | ^~~~~~~ [23/23] Linking target app/dpdk-test-regex Regards Qi