[ofa-general] [PATCH] opensm: remove useless osm_node_get_remote_type()

Sasha Khapyorsky sashak at voltaire.com
Fri Dec 21 14:29:50 PST 2007


Remove useless osm_node_get_remote_type() function.

Signed-off-by: Sasha Khapyorsky <sashak at voltaire.com>
---
 opensm/include/opensm/osm_node.h |   40 --------------------------------------
 opensm/opensm/osm_dump.c         |    2 +-
 2 files changed, 1 insertions(+), 41 deletions(-)

diff --git a/opensm/include/opensm/osm_node.h b/opensm/include/opensm/osm_node.h
index 8af5418..a900e03 100644
--- a/opensm/include/opensm/osm_node.h
+++ b/opensm/include/opensm/osm_node.h
@@ -478,46 +478,6 @@ osm_node_get_remote_base_lid(IN const osm_node_t * const p_node,
 *	Node object
 *********/
 
-/****f* OpenSM: Node/osm_node_get_remote_type
-* NAME
-*	osm_node_get_remote_type
-*
-* DESCRIPTION
-*	Returns the type of the node on the other side
-*	of the wire from the specified port on this node.
-*	The remote node must exist.
-*
-* SYNOPSIS
-*/
-static inline uint8_t
-osm_node_get_remote_type(IN const osm_node_t * const p_node,
-			 IN const uint8_t port_num)
-{
-	osm_node_t *p_remote_node;
-
-	p_remote_node = osm_node_get_remote_node(p_node, port_num, NULL);
-	CL_ASSERT(p_remote_node);
-	return (osm_node_get_type(p_remote_node));
-}
-
-/*
-* PARAMETERS
-*	p_node
-*		[in] Pointer to an osm_node_t object.
-*
-*	port_num
-*		[in] Local port number.
-*
-* RETURN VALUES
-*	Returns the type of the node on the other side
-*	of the wire from the specified port on this node.
-*
-* NOTES
-*
-* SEE ALSO
-*	Node object
-*********/
-
 /****f* OpenSM: Node/osm_node_get_lmc
 * NAME
 *	osm_node_get_lmc
diff --git a/opensm/opensm/osm_dump.c b/opensm/opensm/osm_dump.c
index fa07f83..0cf3d44 100644
--- a/opensm/opensm/osm_dump.c
+++ b/opensm/opensm/osm_dump.c
@@ -99,7 +99,7 @@ static void dump_ucast_path_distribution(cl_map_item_t * p_map_item, void *cxt)
 		remote_guid_ho =
 		    cl_ntoh64(osm_node_get_node_guid(p_remote_node));
 
-		switch (osm_node_get_remote_type(p_node, i)) {
+		switch (osm_node_get_type(p_remote_node)) {
 		case IB_NODE_TYPE_SWITCH:
 			osm_log_printf(&p_osm->log, OSM_LOG_DEBUG,
 				       " (link to switch");
-- 
1.5.3.4.206.g58ba4




More information about the general mailing list