net/i40e: fix flush of flow director filter
authorWei Zhao <wei.zhao1@intel.com>
Wed, 29 Apr 2020 02:03:53 +0000 (10:03 +0800)
committerFerruh Yigit <ferruh.yigit@intel.com>
Tue, 5 May 2020 13:54:25 +0000 (15:54 +0200)
When we flush FDIR filter, we can not call i40e_fdir_teardown()
function as it will free vsi used for FDIR, then the vsi->base_queue
will be freed from pf->qp_pool, but vsi->base_queue can only get
once when do dev init in i40e_pf_setup(). If we free it, it will
never be alloc again.

Bugzilla ID: 404
Fixes: 2e67a7fbf3ff ("net/i40e: config flow director automatically")
Cc: stable@dpdk.org
Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Acked-by: Beilei Xing <beilei.xing@intel.com>
drivers/net/i40e/i40e_flow.c

index 1533d5a..65f8778 100644 (file)
@@ -5145,7 +5145,6 @@ i40e_flow_destroy(struct rte_eth_dev *dev,
 
                /* If the last flow is destroyed, disable fdir. */
                if (!ret && TAILQ_EMPTY(&pf->fdir.fdir_list)) {
-                       i40e_fdir_teardown(pf);
                        i40e_fdir_rx_proc_enable(dev, 0);
                }
                break;
@@ -5343,8 +5342,6 @@ i40e_flow_flush_fdir_filter(struct i40e_pf *pf)
                        pf->fdir.inset_flag[pctype] = 0;
        }
 
-       i40e_fdir_teardown(pf);
-
        return ret;
 }