Tested-by: zhiminx.hu...@intel.com Regards, HuangZhiMin
-----Original Message----- From: dev [mailto:dev-boun...@dpdk.org] On Behalf Of Jiang Mao Sent: Tuesday, June 9, 2020 10:26 AM To: Ye, Xiaolong <xiaolong...@intel.com> Cc: dev@dpdk.org; sta...@dpdk.org; Jiang, MaoX <maox.ji...@intel.com> 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 left, print a warning message. Fixes: 4861cde461 (i40e: new poll mode driver) Cc: sta...@dpdk.org Signed-off-by: Jiang Mao <maox.ji...@intel.com> --- 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 = RTE_MIN(vsi->nb_qps, RTE_MAX_RXTX_INTR_VEC_ID); } + } else if (type == I40E_VSI_FDIR) { + ret = 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 = 0; + vsi->nb_msix = 0; + } else { + vsi->msix_intr = ret; + vsi->nb_msix = 1; + } + } else if (type != I40E_VSI_SRIOV) { ret = i40e_res_pool_alloc(&pf->msix_pool, 1); if (ret < 0) { -- 2.17.1