From patchwork Wed Oct 7 17:54:46 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tony Nguyen X-Patchwork-Id: 11821369 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-12.8 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id DB89CC41604 for ; Wed, 7 Oct 2020 17:55:09 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 8EFF321775 for ; Wed, 7 Oct 2020 17:55:09 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728793AbgJGRzI (ORCPT ); Wed, 7 Oct 2020 13:55:08 -0400 Received: from mga17.intel.com ([192.55.52.151]:18440 "EHLO mga17.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728770AbgJGRzB (ORCPT ); Wed, 7 Oct 2020 13:55:01 -0400 IronPort-SDR: 0S0EBdTrjt8dAZfxb/g4Gnb06GX2zyYCmrRrNK/4JJIHAtxIIQy2ANiCFuVl/uqNZfTm/qa2AW 0SZHUzsj3XAg== X-IronPort-AV: E=McAfee;i="6000,8403,9767"; a="144957658" X-IronPort-AV: E=Sophos;i="5.77,347,1596524400"; d="scan'208";a="144957658" X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga005.fm.intel.com ([10.253.24.32]) by fmsmga107.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 07 Oct 2020 10:54:59 -0700 IronPort-SDR: H7tzg2OIO+2uhoY67Ib/yJhY82PEzhbC6MAIskRfqVou8wFlD7ARuyXjVJV7rigMFtvW3VjZS4 hJ0SPw5wDknQ== X-IronPort-AV: E=Sophos;i="5.77,347,1596524400"; d="scan'208";a="518935797" Received: from jtkirshe-desk1.jf.intel.com ([134.134.177.86]) by fmsmga005-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 07 Oct 2020 10:54:59 -0700 From: Tony Nguyen To: davem@davemloft.net, kuba@kernel.org Cc: Bixuan Cui , netdev@vger.kernel.org, nhorman@redhat.com, sassmann@redhat.com, anthony.l.nguyen@intel.com, Aaron Brown Subject: [net-next 7/8] ice: Fix pointer cast warnings Date: Wed, 7 Oct 2020 10:54:46 -0700 Message-Id: <20201007175447.647867-8-anthony.l.nguyen@intel.com> X-Mailer: git-send-email 2.26.2 In-Reply-To: <20201007175447.647867-1-anthony.l.nguyen@intel.com> References: <20201007175447.647867-1-anthony.l.nguyen@intel.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org From: Bixuan Cui pointers should be casted to unsigned long to avoid -Wpointer-to-int-cast warnings: drivers/net/ethernet/intel/ice/ice_flow.h:197:33: warning: cast from pointer to integer of different size drivers/net/ethernet/intel/ice/ice_flow.h:198:32: warning: cast to pointer from integer of different size Signed-off-by: Bixuan Cui Tested-by: Aaron Brown Signed-off-by: Tony Nguyen --- drivers/net/ethernet/intel/ice/ice_flow.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/net/ethernet/intel/ice/ice_flow.h b/drivers/net/ethernet/intel/ice/ice_flow.h index 3913da2116d2..829f90b1e998 100644 --- a/drivers/net/ethernet/intel/ice/ice_flow.h +++ b/drivers/net/ethernet/intel/ice/ice_flow.h @@ -194,8 +194,8 @@ struct ice_flow_entry { u16 entry_sz; }; -#define ICE_FLOW_ENTRY_HNDL(e) ((u64)e) -#define ICE_FLOW_ENTRY_PTR(h) ((struct ice_flow_entry *)(h)) +#define ICE_FLOW_ENTRY_HNDL(e) ((u64)(uintptr_t)e) +#define ICE_FLOW_ENTRY_PTR(h) ((struct ice_flow_entry *)(uintptr_t)(h)) struct ice_flow_prof { struct list_head l_entry;