From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by dpdk.org (Postfix) with ESMTP id 22062282 for ; Wed, 10 Dec 2014 11:47:01 +0100 (CET) Received: from orsmga002.jf.intel.com ([10.7.209.21]) by orsmga102.jf.intel.com with ESMTP; 10 Dec 2014 02:45:38 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.07,551,1413270000"; d="scan'208";a="651488702" Received: from shvmail01.sh.intel.com ([10.239.29.42]) by orsmga002.jf.intel.com with ESMTP; 10 Dec 2014 02:46:58 -0800 Received: from shecgisg003.sh.intel.com (shecgisg003.sh.intel.com [10.239.29.90]) by shvmail01.sh.intel.com with ESMTP id sBAAkuZI032173; Wed, 10 Dec 2014 18:46:56 +0800 Received: from shecgisg003.sh.intel.com (localhost [127.0.0.1]) by shecgisg003.sh.intel.com (8.13.6/8.13.6/SuSE Linux 0.8) with ESMTP id sBAAksk5007646; Wed, 10 Dec 2014 18:46:56 +0800 Received: (from dayuqiu@localhost) by shecgisg003.sh.intel.com (8.13.6/8.13.6/Submit) id sBAAkrYr007642; Wed, 10 Dec 2014 18:46:53 +0800 From: Michael Qiu To: dev@dpdk.org Date: Wed, 10 Dec 2014 18:46:42 +0800 Message-Id: <1418208402-7597-3-git-send-email-michael.qiu@intel.com> X-Mailer: git-send-email 1.7.4.1 In-Reply-To: <1418208402-7597-1-git-send-email-michael.qiu@intel.com> References: <1417684369-21330-1-git-send-email-michael.qiu@intel.com> <1418208402-7597-1-git-send-email-michael.qiu@intel.com> Subject: [dpdk-dev] [PATCH 2/2] Fix compile issue of eal with icc compile 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: Wed, 10 Dec 2014 10:47:03 -0000 lib/librte_eal/linuxapp/eal/eal.c(461): error #2259: non-pointer conversion from "long long" to "void *" may lose significant bits RTE_PTR_ALIGN_CEIL((uintptr_t)addr, RTE_PGSIZE_16M); The root cause is that "RTE_PGSIZE_16M" is defined as unsigned long long. But in i686 platform "void *" is 32-bit. It is safe to cast to size_t and make it works in both 32 & 64-bit platform. Signed-off-by: Michael Qiu --- lib/librte_eal/linuxapp/eal/eal.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/librte_eal/linuxapp/eal/eal.c b/lib/librte_eal/linuxapp/eal/eal.c index 40b462e..37e4419 100644 --- a/lib/librte_eal/linuxapp/eal/eal.c +++ b/lib/librte_eal/linuxapp/eal/eal.c @@ -458,7 +458,7 @@ eal_parse_base_virtaddr(const char *arg) * it can align to 2MB for x86. So this alignment can also be used * on x86 */ internal_config.base_virtaddr = - RTE_PTR_ALIGN_CEIL((uintptr_t)addr, RTE_PGSIZE_16M); + RTE_PTR_ALIGN_CEIL((uintptr_t)addr, (size_t)RTE_PGSIZE_16M); return 0; } -- 1.9.3