From patchwork Mon Oct 29 23:44:59 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Al Chu X-Patchwork-Id: 1668001 X-Patchwork-Delegate: alexne@voltaire.com Return-Path: X-Original-To: patchwork-linux-rdma@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork2.kernel.org (Postfix) with ESMTP id B4D96DFB7A for ; Mon, 29 Oct 2012 23:54:41 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1761423Ab2J2Xyl (ORCPT ); Mon, 29 Oct 2012 19:54:41 -0400 Received: from prdiron-1.llnl.gov ([128.15.143.171]:17376 "EHLO prdiron-1.llnl.gov" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1758880Ab2J2Xyk (ORCPT ); Mon, 29 Oct 2012 19:54:40 -0400 X-Attachments: Received: from auk59.llnl.gov (HELO [134.9.93.24]) ([134.9.93.24]) by prdiron-1.llnl.gov with ESMTP; 29 Oct 2012 16:44:59 -0700 Subject: [PATCH 1/2] opensm: Fix signed vs unsigned int comparison From: Albert Chu To: linux-rdma@vger.kernel.org Date: Mon, 29 Oct 2012 16:44:59 -0700 Message-Id: <1351554299.25353.20.camel@auk59.llnl.gov> Mime-Version: 1.0 X-Mailer: Evolution 2.12.3 (2.12.3-19.el5) Sender: linux-rdma-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org Signed-off-by: Albert Chu --- opensm/osm_congestion_control.c | 2 +- opensm/osm_perfmgr.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/opensm/osm_congestion_control.c b/opensm/osm_congestion_control.c index 7f1c8fa..b5d9cdb 100644 --- a/opensm/osm_congestion_control.c +++ b/opensm/osm_congestion_control.c @@ -526,7 +526,7 @@ static void cc_poller_send(osm_congestion_control_t *p_cc, if (status == IB_SUCCESS) { cl_atomic_inc(&p_cc->outstanding_mads_on_wire); if (p_cc->outstanding_mads_on_wire > - p_opt->cc_max_outstanding_mads) + (int32_t)p_opt->cc_max_outstanding_mads) cl_event_wait_on(&p_cc->sig_mads_on_wire_continue, EVENT_NO_TIMEOUT, TRUE); diff --git a/opensm/osm_perfmgr.c b/opensm/osm_perfmgr.c index ee2392c..98b4c07 100644 --- a/opensm/osm_perfmgr.c +++ b/opensm/osm_perfmgr.c @@ -420,7 +420,7 @@ static ib_api_status_t perfmgr_send_pc_mad(osm_perfmgr_t * perfmgr, /* pause thread if there are too many outstanding requests */ cl_atomic_inc(&(perfmgr->outstanding_queries)); if (perfmgr->outstanding_queries > - perfmgr->max_outstanding_queries) { + (int32_t)perfmgr->max_outstanding_queries) { perfmgr->sweep_state = PERFMGR_SWEEP_SUSPENDED; cl_event_wait_on(&perfmgr->sig_query, EVENT_NO_TIMEOUT, TRUE);