From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 4E413A04A5; Wed, 17 Jun 2020 07:43:32 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 3022F1BFED; Wed, 17 Jun 2020 07:43:32 +0200 (CEST) Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) by dpdk.org (Postfix) with ESMTP id 531821BFD1; Wed, 17 Jun 2020 07:43:30 +0200 (CEST) IronPort-SDR: 7WxsL2XLlJsimY9kfYpyUwRsGhS87rKH+PoPrTZ9bP3isoFGPQfyigIX+Fy4dMT5KI+byebO+N OrmWfGsD2AeA== X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga007.jf.intel.com ([10.7.209.58]) by fmsmga105.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 16 Jun 2020 22:43:29 -0700 IronPort-SDR: XVd7AeH+PqR+/247s7pcPw7qm/iVlsYBNEhN3kXCt1trOw/g8aJRlLDrLw1SywGM44TKL/Cls8 PVbf8um6mr/g== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.73,521,1583222400"; d="scan'208";a="262450384" Received: from fmsmsx107.amr.corp.intel.com ([10.18.124.205]) by orsmga007.jf.intel.com with ESMTP; 16 Jun 2020 22:43:29 -0700 Received: from fmsmsx112.amr.corp.intel.com (10.18.116.6) by fmsmsx107.amr.corp.intel.com (10.18.124.205) with Microsoft SMTP Server (TLS) id 14.3.439.0; Tue, 16 Jun 2020 22:43:28 -0700 Received: from cdsmsx104.ccr.corp.intel.com (172.17.3.38) by FMSMSX112.amr.corp.intel.com (10.18.116.6) with Microsoft SMTP Server (TLS) id 14.3.439.0; Tue, 16 Jun 2020 22:43:28 -0700 Received: from cdsmsx102.ccr.corp.intel.com ([169.254.2.8]) by CDSMSX104.ccr.corp.intel.com ([172.17.3.38]) with mapi id 14.03.0439.000; Wed, 17 Jun 2020 13:43:26 +0800 From: "Huang, ZhiminX" To: "Jiang, MaoX" CC: "dev@dpdk.org" , "stable@dpdk.org" , "Jiang, MaoX" Thread-Topic: [dpdk-dev] [PATCH 2/2] net/i40e: fix fdir allocating msix resource error Thread-Index: AQHWPgfI20uO1f/BAUus0oFR3pmfkKjcWCTg Date: Wed, 17 Jun 2020 05:43:24 +0000 Message-ID: <1DCDE90B92229844B9E6C0E67C1C8D6B046D2DC6@CDSMSX102.ccr.corp.intel.com> References: <20200609022538.27665-1-maox.jiang@intel.com> <20200609022538.27665-2-maox.jiang@intel.com> In-Reply-To: <20200609022538.27665-2-maox.jiang@intel.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [172.17.6.105] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: Re: [dpdk-dev] [PATCH 2/2] net/i40e: fix fdir allocating msix resource error 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: , Errors-To: dev-bounces@dpdk.org Sender: "dev" Tested-by: zhiminx.huang@intel.com Regards, HuangZhiMin -----Original Message----- From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Jiang Mao Sent: Tuesday, June 9, 2020 10:26 AM To: Ye, Xiaolong Cc: dev@dpdk.org; stable@dpdk.org; Jiang, MaoX Subject: [dpdk-dev] [PATCH 2/2] net/i40e: fix fdir allocating msix resource= error Fdir allocating msix resource is not strictly necessary, if no resource lef= t, print a warning message. Fixes: 4861cde461 (i40e: new poll mode driver) Cc: stable@dpdk.org Signed-off-by: Jiang Mao --- drivers/net/i40e/i40e_ethdev.c | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/drivers/net/i40e/i40e_ethdev.c b/drivers/net/i40e/i40e_ethdev.= c index 33ed556c8..acc43077d 100644 --- a/drivers/net/i40e/i40e_ethdev.c +++ b/drivers/net/i40e/i40e_ethdev.c @@ -5744,6 +5744,17 @@ i40e_vsi_setup(struct i40e_pf *pf, vsi->nb_msix =3D RTE_MIN(vsi->nb_qps, RTE_MAX_RXTX_INTR_VEC_ID); } + } else if (type =3D=3D I40E_VSI_FDIR) { + ret =3D i40e_res_pool_alloc(&pf->msix_pool, 1); + if (ret < 0) { + PMD_DRV_LOG(WARNING, "MSIX vectors used up, FDIR can`t bind interrupt")= ; + vsi->msix_intr =3D 0; + vsi->nb_msix =3D 0; + } else { + vsi->msix_intr =3D ret; + vsi->nb_msix =3D 1; + } + } else if (type !=3D I40E_VSI_SRIOV) { ret =3D i40e_res_pool_alloc(&pf->msix_pool, 1); if (ret < 0) { -- 2.17.1