To avoid code copying, need to make this function accessible by other
files.

Al

-- 
Albert Chu
[EMAIL PROTECTED]
925-422-5311
Computer Scientist
High Performance Systems Division
Lawrence Livermore National Laboratory
>From ac4d94bb784f31954b9494933010bfdcd09e634f Mon Sep 17 00:00:00 2001
From: Albert L. Chu <[EMAIL PROTECTED]>
Date: Thu, 22 May 2008 10:14:56 -0700
Subject: [PATCH] make osm_ucast_mgr_process_port public


Signed-off-by: Albert L. Chu <[EMAIL PROTECTED]>
---
 opensm/include/opensm/osm_ucast_mgr.h |   27 +++++++++++++++++++++++++++
 opensm/opensm/osm_ucast_mgr.c         |   12 ++++++------
 2 files changed, 33 insertions(+), 6 deletions(-)

diff --git a/opensm/include/opensm/osm_ucast_mgr.h b/opensm/include/opensm/osm_ucast_mgr.h
index 0317c93..25972c3 100644
--- a/opensm/include/opensm/osm_ucast_mgr.h
+++ b/opensm/include/opensm/osm_ucast_mgr.h
@@ -231,6 +231,33 @@ osm_ucast_mgr_init(IN osm_ucast_mgr_t * const p_mgr, IN struct osm_sm * sm);
 *	osm_ucast_mgr_destroy
 *********/
 
+/****f* OpenSM: Unicast Manager/osm_ucast_mgr_process_port
+* NAME
+*	osm_ucast_mgr_process_port
+*
+* DESCRIPTION
+*	The osm_ucast_mgr_process_port function processes a port
+*	and determines its routing.
+*
+* SYNOPSIS
+*/
+void
+osm_ucast_mgr_process_port(IN osm_ucast_mgr_t * const p_mgr,
+			   IN osm_switch_t * const p_sw,
+			   IN osm_port_t * const p_port);
+/*
+* PARAMETERS
+*	p_mgr
+*		[in] Pointer to an osm_ucast_mgr_t object.
+*
+*	p_sw	
+*		[in] Pointer to an osm_switch_t object.
+*
+*	p_port
+*		[in] Pointer to an osm_port_t object.
+*
+*********/
+
 /****f* OpenSM: Unicast Manager/osm_ucast_mgr_set_fwd_table
 * NAME
 *	osm_ucast_mgr_set_fwd_table
diff --git a/opensm/opensm/osm_ucast_mgr.c b/opensm/opensm/osm_ucast_mgr.c
index 938db84..edff8a1 100644
--- a/opensm/opensm/osm_ucast_mgr.c
+++ b/opensm/opensm/osm_ucast_mgr.c
@@ -192,10 +192,10 @@ __osm_ucast_mgr_process_neighbor(IN osm_ucast_mgr_t * const p_mgr,
 
 /**********************************************************************
  **********************************************************************/
-static void
-__osm_ucast_mgr_process_port(IN osm_ucast_mgr_t * const p_mgr,
-			     IN osm_switch_t * const p_sw,
-			     IN osm_port_t * const p_port)
+void
+osm_ucast_mgr_process_port(IN osm_ucast_mgr_t * const p_mgr,
+			   IN osm_switch_t * const p_sw,
+			   IN osm_port_t * const p_port)
 {
 	uint16_t min_lid_ho;
 	uint16_t max_lid_ho;
@@ -219,7 +219,7 @@ __osm_ucast_mgr_process_port(IN osm_ucast_mgr_t * const p_mgr,
 		remote_guids = malloc(sizeof(osm_switch_guid_count_t) * lids_per_port);
 		if (remote_guids == NULL) {
 			osm_log(p_mgr->p_log, OSM_LOG_ERROR,
-				"__osm_ucast_mgr_process_port: ERR 3A09: "
+				"osm_ucast_mgr_process_port: ERR 3A09: "
 				"Cannot allocate array. Insufficient memory\n");
 			goto Exit;
 		}
@@ -501,7 +501,7 @@ __osm_ucast_mgr_process_tbl(IN cl_map_item_t * const p_map_item,
 	for (p_port = (osm_port_t *) cl_qmap_head(p_port_tbl);
 	     p_port != (osm_port_t *) cl_qmap_end(p_port_tbl);
 	     p_port = (osm_port_t *) cl_qmap_next(&p_port->map_item)) {
-		__osm_ucast_mgr_process_port(p_mgr, p_sw, p_port);
+		osm_ucast_mgr_process_port(p_mgr, p_sw, p_port);
 	}
 
 	osm_ucast_mgr_set_fwd_table(p_mgr, p_sw);
-- 
1.5.1

_______________________________________________
general mailing list
[email protected]
http://lists.openfabrics.org/cgi-bin/mailman/listinfo/general

To unsubscribe, please visit http://openib.org/mailman/listinfo/openib-general

Reply via email to