X-Git-Url: http://git.droids-corp.org/?a=blobdiff_plain;f=drivers%2Fnet%2Fmlx5%2Flinux%2Fmlx5_os.c;h=1ff2b8dc2284868ef1421e9383cc0c5a70c44dc6;hb=cf8971db657c7b1d940d66274ff73ae8cb8b0708;hp=bee055772ba9b2e4286ad5f7d31c714ba7c644cd;hpb=e3032e9c73f4791e2cdbab5a37f322c288d7e2aa;p=dpdk.git diff --git a/drivers/net/mlx5/linux/mlx5_os.c b/drivers/net/mlx5/linux/mlx5_os.c index bee055772b..1ff2b8dc22 100644 --- a/drivers/net/mlx5/linux/mlx5_os.c +++ b/drivers/net/mlx5/linux/mlx5_os.c @@ -673,46 +673,6 @@ out: return ret; } -/** - * DV flow counter mode detect and config. - * - * @param dev - * Pointer to rte_eth_dev structure. - * - */ -static void -mlx5_flow_counter_mode_config(struct rte_eth_dev *dev __rte_unused) -{ -#ifdef HAVE_IBV_FLOW_DV_SUPPORT - struct mlx5_priv *priv = dev->data->dev_private; - struct mlx5_dev_ctx_shared *sh = priv->sh; - struct mlx5_hca_attr *hca_attr = &sh->cdev->config.hca_attr; - bool fallback; - -#ifndef HAVE_IBV_DEVX_ASYNC - fallback = true; -#else - fallback = false; - if (!sh->cdev->config.devx || !priv->config.dv_flow_en || - !hca_attr->flow_counters_dump || - !(hca_attr->flow_counter_bulk_alloc_bitmap & 0x4) || - (mlx5_flow_dv_discover_counter_offset_support(dev) == -ENOTSUP)) - fallback = true; -#endif - if (fallback) - DRV_LOG(INFO, "Use fall-back DV counter management. Flow " - "counter dump:%d, bulk_alloc_bitmap:0x%hhx.", - hca_attr->flow_counters_dump, - hca_attr->flow_counter_bulk_alloc_bitmap); - /* Initialize fallback mode only on the port initializes sh. */ - if (sh->refcnt == 1) - sh->cmng.counter_fallback = fallback; - else if (fallback != sh->cmng.counter_fallback) - DRV_LOG(WARNING, "Port %d in sh has different fallback mode " - "with others:%d.", PORT_ID(priv), fallback); -#endif -} - /** * DR flow drop action support detect. *