src/drivers/trex_i40e_fdir.c
void
trex_i40e_fdir_teardown(struct i40e_pf *pf)
{
	struct i40e_hw *hw = I40E_PF_TO_HW(pf);
	struct i40e_vsi *vsi;

	vsi = pf->fdir.fdir_vsi;
	if (!vsi)
		return;
	int err = i40e_switch_tx_queue(hw, vsi->base_queue, FALSE);
	if (err)
		PMD_DRV_LOG(DEBUG, "Failed to do FDIR TX switch off");
	err = i40e_switch_rx_queue(hw, vsi->base_queue, FALSE);
	if (err)
		PMD_DRV_LOG(DEBUG, "Failed to do FDIR RX switch off");
	i40e_dev_rx_queue_release(pf->fdir.rxq);
	pf->fdir.rxq = NULL;
	i40e_dev_tx_queue_release(pf->fdir.txq);
	pf->fdir.txq = NULL;
	i40e_vsi_release(vsi);
	pf->fdir.fdir_vsi = NULL;
}
/*
 * i40e_fdir_teardown - release the Flow Director resources
 * @pf: board private structure
 */
release the Flow Director resources
@pf: board private structure
release the Flow Director resources @pf : board private structure
void
trex_i40e_fdir_teardown(struct i40e_pf *pf)
{
	struct i40e_hw *hw = I40E_PF_TO_HW(pf);
	struct i40e_vsi *vsi;
	vsi = pf->fdir.fdir_vsi;
	if (!vsi)
		return;
	int err = i40e_switch_tx_queue(hw, vsi->base_queue, FALSE);
	if (err)
		PMD_DRV_LOG(DEBUG, "Failed to do FDIR TX switch off");
	err = i40e_switch_rx_queue(hw, vsi->base_queue, FALSE);
	if (err)
		PMD_DRV_LOG(DEBUG, "Failed to do FDIR RX switch off");
	i40e_dev_rx_queue_release(pf->fdir.rxq);
	pf->fdir.rxq = NULL;
	i40e_dev_tx_queue_release(pf->fdir.txq);
	pf->fdir.txq = NULL;
	i40e_vsi_release(vsi);
	pf->fdir.fdir_vsi = NULL;
}
void trex_i40e_fdir_teardown ( struct i40e_pf * pf ) { struct i40e_hw * hw = I40E_PF_TO_HW ( pf ) ; struct i40e_vsi * vsi ; vsi = pf -> fdir . fdir_vsi ; if ( ! vsi ) return ; int err = i40e_switch_tx_queue ( hw , vsi -> base_queue , FALSE ) ; if ( err ) PMD_DRV_LOG ( DEBUG , " " ) ; err = i40e_switch_rx_queue ( hw , vsi -> base_queue , FALSE ) ; if ( err ) PMD_DRV_LOG ( DEBUG , " " ) ; i40e_dev_rx_queue_release ( pf -> fdir . rxq ) ; pf -> fdir . rxq = NULL ; i40e_dev_tx_queue_release ( pf -> fdir . txq ) ; pf -> fdir . txq = NULL ; i40e_vsi_release ( vsi ) ; pf -> fdir . fdir_vsi = NULL ; }
i40e_fdir_teardown - release the Flow Director resources
 @pf: board private structure
i40e_fdir_teardown - release the Flow Director resources @pf : board private structure