From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 800FBA00BE; Mon, 27 Apr 2020 15:34:21 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 576BE1D444; Mon, 27 Apr 2020 15:34:21 +0200 (CEST) Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) by dpdk.org (Postfix) with ESMTP id 0B71F1D428 for ; Mon, 27 Apr 2020 15:34:19 +0200 (CEST) IronPort-SDR: NaWhNpfgja9j2tH150KmdDwVpbxqRCCZXDHa9dNRVj+X+FTFMrEK+taEfgXh83nGHF7GIXVszH fYujqJsWXnbQ== X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga005.jf.intel.com ([10.7.209.41]) by orsmga101.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 Apr 2020 06:34:19 -0700 IronPort-SDR: kumI3lNwbB54stc3ap/gRtCxvrBB/Yersa+Pfoz9y2pE8UsHMA8/Y2dvnpmm1Zmo3OVMhYW2Rp 7PcVN/unscjg== X-IronPort-AV: E=Sophos;i="5.73,324,1583222400"; d="scan'208";a="431777398" Received: from bricha3-mobl.ger.corp.intel.com ([10.249.32.186]) by orsmga005-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-SHA; 27 Apr 2020 06:34:17 -0700 Date: Mon, 27 Apr 2020 14:34:13 +0100 From: Bruce Richardson To: David Marchand Cc: dev@dpdk.org, Ori Kam , Thomas Monjalon , Ferruh Yigit , Andrew Rybchenko , Xiao Zhang Message-ID: <20200427133413.GA1848@bricha3-MOBL.ger.corp.intel.com> References: <20200427132341.27681-1-david.marchand@redhat.com> <20200427132341.27681-4-david.marchand@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200427132341.27681-4-david.marchand@redhat.com> Subject: Re: [dpdk-dev] [PATCH 3/3] ethdev: fix build warning on 64-bit value X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list 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 Mon, Apr 27, 2020 at 03:23:41PM +0200, David Marchand wrote: > Building OVS with dpdk, sparse complains about 64-bit constant being > passed as a normal integer that can't fit it: > error: constant 0xffffffffffffffff is so big it is unsigned long > > Fixes: ecbc8570131d ("ethdev: add PFCP header to flow API") > > Signed-off-by: David Marchand > --- > lib/librte_ethdev/rte_flow.h | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/lib/librte_ethdev/rte_flow.h b/lib/librte_ethdev/rte_flow.h > index 132b44edc6..1fb94f35e8 100644 > --- a/lib/librte_ethdev/rte_flow.h > +++ b/lib/librte_ethdev/rte_flow.h > @@ -1534,7 +1534,7 @@ struct rte_flow_item_pfcp { > #ifndef __cplusplus > static const struct rte_flow_item_pfcp rte_flow_item_pfcp_mask = { > .s_field = 0x01, > - .seid = RTE_BE64(0xffffffffffffffff), > + .seid = RTE_BE64(UINT64_C(0xffffffffffffffff)), Rather than cast, why not put "ULL" at the end. If we are going to cast, why not just put "-1" in to save some digits. /Bruce