From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga04.intel.com (mga04.intel.com [192.55.52.120]) by dpdk.org (Postfix) with ESMTP id DDA779A9C for ; Tue, 14 Jun 2016 18:17:29 +0200 (CEST) Received: from orsmga002.jf.intel.com ([10.7.209.21]) by fmsmga104.fm.intel.com with ESMTP; 14 Jun 2016 09:17:30 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.26,471,1459839600"; d="scan'208";a="997465356" Received: from irvmail001.ir.intel.com ([163.33.26.43]) by orsmga002.jf.intel.com with ESMTP; 14 Jun 2016 09:17:28 -0700 Received: from sivswdev02.ir.intel.com (sivswdev02.ir.intel.com [10.237.217.46]) by irvmail001.ir.intel.com (8.14.3/8.13.6/MailSET/Hub) with ESMTP id u5EGHRjk026148; Tue, 14 Jun 2016 17:17:27 +0100 Received: from sivswdev02.ir.intel.com (localhost [127.0.0.1]) by sivswdev02.ir.intel.com with ESMTP id u5EGHQXl025735; Tue, 14 Jun 2016 17:17:26 +0100 Received: (from fyigit@localhost) by sivswdev02.ir.intel.com with id u5EGHQAV025731; Tue, 14 Jun 2016 17:17:26 +0100 From: Ferruh Yigit To: dev@dpdk.org Cc: Adrien Mazarguil , Ferruh Yigit Date: Tue, 14 Jun 2016 17:17:24 +0100 Message-Id: <1465921044-25700-1-git-send-email-ferruh.yigit@intel.com> X-Mailer: git-send-email 1.7.4.1 In-Reply-To: <1465917730-10713-1-git-send-email-ferruh.yigit@intel.com> References: <1465917730-10713-1-git-send-email-ferruh.yigit@intel.com> Subject: [dpdk-dev] [PATCH v3] mlx: fix icc compilation error X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Jun 2016 16:17:30 -0000 Compilation errors: mlx4: CC mlx4.o .../dpdk/drivers/net/mlx4/mlx4.c(5409): error #188: enumerated type mixed with another type priv->intr_handle.type = 0; ^ mlx5: CC em_rxtx.o .../dpdk/drivers/net/mlx5/mlx5_rxq.c(282): error #188: enumerated type mixed with another type enum hash_rxq_type type = 0; ^ .../dpdk/drivers/net/mlx5/mlx5_rxq.c(622): error #188: enumerated type mixed with another type if (!priv_allow_flow_type(priv, i)) { ^ more same type of error Fixes: c4da6caa426d ("mlx4: handle link status interrupts") Fixes: 198a3c339a8f ("mlx5: handle link status interrupts") Fixes: 0d2186743d62 ("mlx5: manage all special flow types at once") Fixes: 612ad38209f7 ("mlx5: fix hash Rx queue type in RSS mode") Fixes: 083c2dd31776 ("mlx5: refactor special flows handling") Signed-off-by: Ferruh Yigit --- drivers/net/mlx4/mlx4.c | 2 +- drivers/net/mlx5/mlx5_ethdev.c | 2 +- drivers/net/mlx5/mlx5_rxmode.c | 8 ++++++-- drivers/net/mlx5/mlx5_rxq.c | 8 +++++--- 4 files changed, 13 insertions(+), 7 deletions(-) diff --git a/drivers/net/mlx4/mlx4.c b/drivers/net/mlx4/mlx4.c index 9ed1491..8c9e713 100644 --- a/drivers/net/mlx4/mlx4.c +++ b/drivers/net/mlx4/mlx4.c @@ -5406,7 +5406,7 @@ priv_dev_interrupt_handler_uninstall(struct priv *priv, struct rte_eth_dev *dev) rte_eal_alarm_cancel(mlx4_dev_link_status_handler, dev); priv->pending_alarm = 0; priv->intr_handle.fd = 0; - priv->intr_handle.type = 0; + priv->intr_handle.type = RTE_INTR_HANDLE_UNKNOWN; } /** diff --git a/drivers/net/mlx5/mlx5_ethdev.c b/drivers/net/mlx5/mlx5_ethdev.c index 36b369e..6f5ece9 100644 --- a/drivers/net/mlx5/mlx5_ethdev.c +++ b/drivers/net/mlx5/mlx5_ethdev.c @@ -1012,7 +1012,7 @@ priv_dev_interrupt_handler_uninstall(struct priv *priv, struct rte_eth_dev *dev) rte_eal_alarm_cancel(mlx5_dev_link_status_handler, dev); priv->pending_alarm = 0; priv->intr_handle.fd = 0; - priv->intr_handle.type = 0; + priv->intr_handle.type = RTE_INTR_HANDLE_UNKNOWN; } /** diff --git a/drivers/net/mlx5/mlx5_rxmode.c b/drivers/net/mlx5/mlx5_rxmode.c index 3a55f63..3e779be 100644 --- a/drivers/net/mlx5/mlx5_rxmode.c +++ b/drivers/net/mlx5/mlx5_rxmode.c @@ -355,7 +355,9 @@ priv_special_flow_enable_all(struct priv *priv) { enum hash_rxq_flow_type flow_type; - for (flow_type = 0; flow_type != HASH_RXQ_FLOW_TYPE_MAC; ++flow_type) { + for (flow_type = HASH_RXQ_FLOW_TYPE_PROMISC; + flow_type != HASH_RXQ_FLOW_TYPE_MAC; + ++flow_type) { int ret; ret = priv_special_flow_enable(priv, flow_type); @@ -380,7 +382,9 @@ priv_special_flow_disable_all(struct priv *priv) { enum hash_rxq_flow_type flow_type; - for (flow_type = 0; flow_type != HASH_RXQ_FLOW_TYPE_MAC; ++flow_type) + for (flow_type = HASH_RXQ_FLOW_TYPE_PROMISC; + flow_type != HASH_RXQ_FLOW_TYPE_MAC; + ++flow_type) priv_special_flow_disable(priv, flow_type); } diff --git a/drivers/net/mlx5/mlx5_rxq.c b/drivers/net/mlx5/mlx5_rxq.c index cbb017b..f09ea8f 100644 --- a/drivers/net/mlx5/mlx5_rxq.c +++ b/drivers/net/mlx5/mlx5_rxq.c @@ -279,7 +279,7 @@ priv_flow_attr(struct priv *priv, struct ibv_exp_flow_attr *flow_attr, static enum hash_rxq_type hash_rxq_type_from_pos(const struct ind_table_init *table, unsigned int pos) { - enum hash_rxq_type type = 0; + enum hash_rxq_type type = HASH_RXQ_TCPV4; assert(pos < table->hash_types_n); do { @@ -616,9 +616,11 @@ priv_allow_flow_type(struct priv *priv, enum hash_rxq_flow_type type) int priv_rehash_flows(struct priv *priv) { - unsigned int i; + enum hash_rxq_flow_type i; - for (i = 0; (i != RTE_DIM((*priv->hash_rxqs)[0].special_flow)); ++i) + for (i = HASH_RXQ_FLOW_TYPE_PROMISC; + i != RTE_DIM((*priv->hash_rxqs)[0].special_flow); + ++i) if (!priv_allow_flow_type(priv, i)) { priv_special_flow_disable(priv, i); } else { -- 2.5.5