From patchwork Thu Sep 9 21:12:21 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Smith, Stan" X-Patchwork-Id: 165521 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id o89LCMWS027961 for ; Thu, 9 Sep 2010 21:12:22 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753481Ab0IIVMV (ORCPT ); Thu, 9 Sep 2010 17:12:21 -0400 Received: from mga02.intel.com ([134.134.136.20]:43644 "EHLO mga02.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753455Ab0IIVMV (ORCPT ); Thu, 9 Sep 2010 17:12:21 -0400 Received: from orsmga002.jf.intel.com ([10.7.209.21]) by orsmga101.jf.intel.com with ESMTP; 09 Sep 2010 14:12:20 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="4.56,342,1280732400"; d="scan'208";a="553104331" Received: from scsmith-mobl1.amr.corp.intel.com (HELO scsmithMOBL1) ([10.7.151.57]) by orsmga002.jf.intel.com with ESMTP; 09 Sep 2010 14:12:20 -0700 From: "Stan C. Smith" To: "Sasha Khapyorsky" Cc: "Linux RDMA" Subject: [PATCH] replace (long*)(long) casting with transportable data type (uintptr_t) Date: Thu, 9 Sep 2010 14:12:21 -0700 Message-ID: <7C00F472050C412BABCB4F2A59CFBD63@amr.corp.intel.com> MIME-Version: 1.0 X-Mailer: Microsoft Office Outlook 11 Thread-Index: ActQY7D1OW4LQUUxQn6C034jCqAxJQ== X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.5579 Sender: linux-rdma-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter1.kernel.org [140.211.167.41]); Thu, 09 Sep 2010 21:12:48 +0000 (UTC) diff --git a/opensm/libvendor/osm_vendor_ibumad_sa.c b/opensm/libvendor/osm_vendor_ibumad_sa.c index 1fdcc47..9180972 100644 --- a/opensm/libvendor/osm_vendor_ibumad_sa.c +++ b/opensm/libvendor/osm_vendor_ibumad_sa.c @@ -85,7 +85,7 @@ __osmv_sa_mad_rcv_cb(IN osm_madw_t * p_madw, /* obtain the sent context since we store it during send in the ni_ctx */ p_query_req_copy = - (osmv_query_req_t *) (long *)(long)(p_req_madw->context.ni_context. + (osmv_query_req_t *) (uintptr_t)(p_req_madw->context.ni_context. node_guid); /* provide the context of the original request in the result */ @@ -181,7 +181,7 @@ static void __osmv_sa_mad_err_cb(IN void *bind_context, IN osm_madw_t * p_madw) /* Obtain the sent context etc */ p_query_req_copy = - (osmv_query_req_t *) (long *)(long)(p_madw->context.ni_context. + (osmv_query_req_t *) (uintptr_t)(p_madw->context.ni_context. node_guid); /* provide the context of the original request in the result */ @@ -433,7 +433,7 @@ __osmv_send_sa_req(IN osmv_sa_bind_info_t * p_bind, } *p_query_req_copy = *p_query_req; p_madw->context.ni_context.node_guid = - (ib_net64_t) (long)p_query_req_copy; + (ib_net64_t) (uintptr_t)p_query_req_copy; /* we can support async as well as sync calls */ sync = ((p_query_req->flags & OSM_SA_FLAGS_SYNC) == OSM_SA_FLAGS_SYNC);