src/dpdk/drivers/net/ixgbe/ixgbe_ethdev.c
int
ixgbe_clear_all_l2_tn_filter(struct rte_eth_dev *dev)
{
	struct ixgbe_l2_tn_info *l2_tn_info =
		IXGBE_DEV_PRIVATE_TO_L2_TN_INFO(dev->data->dev_private);
	struct ixgbe_l2_tn_filter *l2_tn_filter;
	struct ixgbe_l2_tunnel_conf l2_tn_conf;
	int ret = 0;

	while ((l2_tn_filter = TAILQ_FIRST(&l2_tn_info->l2_tn_list))) {
		l2_tn_conf.l2_tunnel_type = l2_tn_filter->key.l2_tn_type;
		l2_tn_conf.tunnel_id      = l2_tn_filter->key.tn_id;
		l2_tn_conf.pool           = l2_tn_filter->pool;
		ret = ixgbe_dev_l2_tunnel_filter_del(dev, &l2_tn_conf);
		if (ret < 0)
			return ret;
	}

	return 0;
}
/* remove all the L2 tunnel filters */
remove all the L2 tunnel filters
remove all the L2 tunnel filters
int
ixgbe_clear_all_l2_tn_filter(struct rte_eth_dev *dev)
{
	struct ixgbe_l2_tn_info *l2_tn_info =
		IXGBE_DEV_PRIVATE_TO_L2_TN_INFO(dev->data->dev_private);
	struct ixgbe_l2_tn_filter *l2_tn_filter;
	struct ixgbe_l2_tunnel_conf l2_tn_conf;
	int ret = 0;
	while ((l2_tn_filter = TAILQ_FIRST(&l2_tn_info->l2_tn_list))) {
		l2_tn_conf.l2_tunnel_type = l2_tn_filter->key.l2_tn_type;
		l2_tn_conf.tunnel_id      = l2_tn_filter->key.tn_id;
		l2_tn_conf.pool           = l2_tn_filter->pool;
		ret = ixgbe_dev_l2_tunnel_filter_del(dev, &l2_tn_conf);
		if (ret < 0)
			return ret;
	}
	return 0;
}
int ixgbe_clear_all_l2_tn_filter ( struct rte_eth_dev * dev ) { struct ixgbe_l2_tn_info * l2_tn_info = IXGBE_DEV_PRIVATE_TO_L2_TN_INFO ( dev -> data -> dev_private ) ; struct ixgbe_l2_tn_filter * l2_tn_filter ; struct ixgbe_l2_tunnel_conf l2_tn_conf ; int ret = 0 ; while ( ( l2_tn_filter = TAILQ_FIRST ( & l2_tn_info -> l2_tn_list ) ) ) { l2_tn_conf . l2_tunnel_type = l2_tn_filter -> key . l2_tn_type ; l2_tn_conf . tunnel_id = l2_tn_filter -> key . tn_id ; l2_tn_conf . pool = l2_tn_filter -> pool ; ret = ixgbe_dev_l2_tunnel_filter_del ( dev , & l2_tn_conf ) ; if ( ret < 0 ) return ret ; } return 0 ; }
remove all the L2 tunnel filters
remove all the L2 tunnel filters