From patchwork Thu Nov 12 20:22:57 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sasha Khapyorsky X-Patchwork-Id: 59644 Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id nACKKg1b008099 for ; Thu, 12 Nov 2009 20:20:43 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753599AbZKLUUg (ORCPT ); Thu, 12 Nov 2009 15:20:36 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1753512AbZKLUUg (ORCPT ); Thu, 12 Nov 2009 15:20:36 -0500 Received: from mail-fx0-f221.google.com ([209.85.220.221]:32849 "EHLO mail-fx0-f221.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753702AbZKLUUf (ORCPT ); Thu, 12 Nov 2009 15:20:35 -0500 Received: by fxm21 with SMTP id 21so2674630fxm.21 for ; Thu, 12 Nov 2009 12:20:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:sender:received:date:from:to :cc:subject:message-id:references:mime-version:content-type :content-disposition:in-reply-to:user-agent; bh=B3FBLouU6srFOUyVxIo/FWkpm/9zx9jpSb2tdXORzpg=; b=Nlv0WymVGi/3zNZi7WDJK3Cjaabnwyj5lH/rlw2ThnKvl9yOkRkY2k5H0beevnYvWG pvq6roYmrmAyT/gPn1b8H9LJ91/ScFLMAnyiJ7LyMQ4chX2QbgyrvoSXkZD0wxi5R4i8 rn8hV8cm7z7AMlYOw1LYBuwa76UGrsaxItIRo= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=sender:date:from:to:cc:subject:message-id:references:mime-version :content-type:content-disposition:in-reply-to:user-agent; b=dM4HMSkTkvis+cUrHAobTK1yeVSMyb4FeIpWs9xUa935LwsPtlwrFjYV1CB9fehFdP DEHYJNcEiL9dJ3G0edFCjvF/0STCo5j5HzTpR0F2HcL+w8qPACMIMfN7n++onrb6PCuw Mp7GF0Y436OaQPzOb1vsAtySr7QI2eqLTfBV8= Received: by 10.103.125.18 with SMTP id c18mr1541438mun.71.1258057240211; Thu, 12 Nov 2009 12:20:40 -0800 (PST) Received: from me.localdomain (85.64.35.106.dynamic.barak-online.net [85.64.35.106]) by mx.google.com with ESMTPS id 23sm5684465mum.44.2009.11.12.12.20.39 (version=TLSv1/SSLv3 cipher=RC4-MD5); Thu, 12 Nov 2009 12:20:39 -0800 (PST) Received: by me.localdomain (Postfix, from userid 1000) id D8BC41209B; Thu, 12 Nov 2009 22:22:57 +0200 (IST) Date: Thu, 12 Nov 2009 22:22:57 +0200 From: Sasha Khapyorsky To: linux-rdma Cc: Sean Hefty , "Smith, Stan" , ofw@lists.openfabrics.org Subject: [PATCH] complib/fleximap: make compar callback to return int Message-ID: <20091112202257.GR7192@me> References: <3F6F638B8D880340AB536D29CD4C1E1912C86E8A8F@orsmsx501.amr.corp.intel.com> <20091004001316.GK17846@me> <20091112191811.GO7192@me> <81D21ED9D6F34BC1B7DA64F50EE5A7DD@amr.corp.intel.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <81D21ED9D6F34BC1B7DA64F50EE5A7DD@amr.corp.intel.com> User-Agent: Mutt/1.5.20 (2009-06-14) Sender: linux-rdma-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org diff --git a/opensm/complib/cl_map.c b/opensm/complib/cl_map.c index b49b4b8..d851bf8 100644 --- a/opensm/complib/cl_map.c +++ b/opensm/complib/cl_map.c @@ -1148,7 +1148,7 @@ cl_fmap_item_t *cl_fmap_get(IN const cl_fmap_t * const p_map, IN const void *const p_key) { cl_fmap_item_t *p_item; - intn_t cmp; + int cmp; CL_ASSERT(p_map); CL_ASSERT(p_map->state == CL_INITIALIZED); @@ -1175,7 +1175,7 @@ cl_fmap_item_t *cl_fmap_get_next(IN const cl_fmap_t * const p_map, { cl_fmap_item_t *p_item; cl_fmap_item_t *p_item_found; - intn_t cmp; + int cmp; CL_ASSERT(p_map); CL_ASSERT(p_map->state == CL_INITIALIZED); @@ -1273,7 +1273,7 @@ cl_fmap_item_t *cl_fmap_insert(IN cl_fmap_t * const p_map, IN cl_fmap_item_t * const p_item) { cl_fmap_item_t *p_insert_at, *p_comp_item; - intn_t cmp = 0; + int cmp = 0; CL_ASSERT(p_map); CL_ASSERT(p_map->state == CL_INITIALIZED); @@ -1575,7 +1575,7 @@ void cl_fmap_delta(IN OUT cl_fmap_t * const p_map1, OUT cl_fmap_t * const p_new, OUT cl_fmap_t * const p_old) { cl_fmap_item_t *p_item1, *p_item2; - intn_t cmp; + int cmp; CL_ASSERT(p_map1); CL_ASSERT(p_map2); diff --git a/opensm/include/complib/cl_fleximap.h b/opensm/include/complib/cl_fleximap.h index 0af8766..ec008cf 100644 --- a/opensm/include/complib/cl_fleximap.h +++ b/opensm/include/complib/cl_fleximap.h @@ -181,7 +181,7 @@ typedef struct _cl_fmap_item { * * SYNOPSIS */ -typedef intn_t +typedef int (*cl_pfn_fmap_cmp_t) (IN const void *const p_key1, IN const void *const p_key2); /* diff --git a/opensm/opensm/osm_subnet.c b/opensm/opensm/osm_subnet.c index cac5e94..dd72a3a 100644 --- a/opensm/opensm/osm_subnet.c +++ b/opensm/opensm/osm_subnet.c @@ -397,7 +397,7 @@ static const opt_rec_t opt_tbl[] = { {0} }; -static long compar_mgids(const void *m1, const void *m2) +static int compar_mgids(const void *m1, const void *m2) { return memcmp(m1, m2, sizeof(ib_gid_t)); }