From mboxrd@z Thu Jan 1 00:00:00 1970 From: Yongseok Koh Subject: Re: [PATCH v2 16/30] net/mlx5: fix clang compilation error Date: Thu, 5 Oct 2017 22:01:40 -0700 Message-ID: <20171006050140.GG19330@yongseok-MBP.local> References: <9603c091a45da3cec77a3122498777960b83b06a.1507207731.git.nelio.laranjeiro@6wind.com> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Cc: dev@dpdk.org, adrien.mazarguil@6wind.com, ferruh.yigit@intel.com, stable@dpdk.org To: Nelio Laranjeiro Return-path: Content-Disposition: inline In-Reply-To: <9603c091a45da3cec77a3122498777960b83b06a.1507207731.git.nelio.laranjeiro@6wind.com> List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On Thu, Oct 05, 2017 at 02:49:48PM +0200, Nelio Laranjeiro wrote: > drivers/net/mlx5/mlx5_rxq.c:606:6: error: comparison of constant 4 > with expression of type 'enum hash_rxq_flow_type' is always true > [-Werror,-Wtautological-constant-out-of-range-compare] > i != (int)RTE_DIM((*priv->hash_rxqs)[0].special_flow); > ~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ > > Clang expects to have an index going upto special_flow size which is > defined by MLX5_MAX_SPECIAL_FLOWS and value is 4. Comparing to an > unrelated enum where index my be lower cause this compilation issue. > > Fixes: 36351ea34b92 ("net/mlx: fix build with icc") > Cc: ferruh.yigit@intel.com > Cc: stable@dpdk.org > > Signed-off-by: Nelio Laranjeiro > --- Acked-by: Yongseok Koh   Thanks