net/mlx5: fix icc compiler warning
authorXueming Li <xuemingl@mellanox.com>
Tue, 17 Oct 2017 02:46:43 +0000 (10:46 +0800)
committerFerruh Yigit <ferruh.yigit@intel.com>
Thu, 26 Oct 2017 00:33:01 +0000 (02:33 +0200)
Initialize variable to avoid ICC compiler warning:
http://www.dpdk.org/ml/archives/dev/2017-October/077971.html

Fixes: f8b9a3bad467 ("net/mlx5: install a socket to exchange a file descriptor")

Signed-off-by: Xueming Li <xuemingl@mellanox.com>
Acked-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com>
drivers/net/mlx5/Makefile
drivers/net/mlx5/mlx5_txq.c

index e78840f..24c0789 100644 (file)
@@ -91,11 +91,6 @@ ifdef CONFIG_RTE_LIBRTE_MLX5_TX_MP_CACHE
 CFLAGS += -DMLX5_PMD_TX_MP_CACHE=$(CONFIG_RTE_LIBRTE_MLX5_TX_MP_CACHE)
 endif
 
-# Disable false positive warning
-ifeq ($(CONFIG_RTE_TOOLCHAIN_ICC),y)
-CFLAGS_mlx5_txq.o += -wd3656
-endif
-
 include $(RTE_SDK)/mk/rte.lib.mk
 
 # Generate and clean-up mlx5_autoconf.h.
index 3d5f033..fbb2630 100644 (file)
@@ -246,6 +246,7 @@ priv_tx_uar_remap(struct priv *priv, int fd)
        int already_mapped;
        size_t page_size = sysconf(_SC_PAGESIZE);
 
+       memset(pages, 0, priv->txqs_n * sizeof(uintptr_t));
        /*
         * As rdma-core, UARs are mapped in size of OS page size.
         * Use aligned address to avoid duplicate mmap.