[openib-general] [PATCH] OpenSM/osm_vendor_sa_api.h: Add InformInfoRecord query result support

Hal Rosenstock halr at voltaire.com
Mon Jul 10 11:06:24 PDT 2006


OpenSM/osm_vendor_sa_api.h: Add InformInfoRecord query result support

Signed-off-by: Hal Rosenstock <halr at voltaire.com>

Index: include/vendor/osm_vendor_sa_api.h
===================================================================
--- include/vendor/osm_vendor_sa_api.h	(revision 8475)
+++ include/vendor/osm_vendor_sa_api.h	(working copy)
@@ -654,6 +654,47 @@ osmv_get_query_mc_rec(
 *	osmv_query_res_t, osm_madw_t, osmv_get_query_result, ib_member_rec_t
 *****/
 
+/****f* OpenSM Vendor SA Client/osmv_get_query_inform_info_rec
+* NAME
+*	osmv_get_query_inform_info_rec
+*
+* DESCRIPTION
+*	Retrieves an InformInfo record result from a MAD returned by
+*	a call to osmv_query_sa().
+*
+* SYNOPSIS
+*/
+static inline ib_inform_info_record_t*
+osmv_get_query_inform_info_rec(
+	IN osm_madw_t		*p_result_madw,
+	IN uint32_t		result_index )
+{
+	ib_sa_mad_t		*p_sa_mad;
+
+	CL_ASSERT( p_result_madw );
+	p_sa_mad = (ib_sa_mad_t*)osm_madw_get_mad_ptr( p_result_madw );
+	CL_ASSERT( p_sa_mad && p_sa_mad->attr_id == IB_MAD_ATTR_INFORM_INFO_RECORD );
+
+        return( (ib_inform_info_record_t*)osmv_get_query_result( p_result_madw,
+                result_index ) );
+}
+/*
+* PARAMETERS
+*	p_result_madw
+*		[in] This is a reference to the MAD returned as a result of the
+*		query.
+*
+*	result_index
+*		[in] A zero-based index indicating which result to return.
+*
+* NOTES
+*	This call returns a pointer to the start of a service record result from
+*	a call to osmv_query_sa().
+*
+* SEE ALSO
+*	osmv_query_res_t, osm_madw_t, osmv_get_query_result, ib_inform_info_record_t
+*****/
+
 /****f* OpenSM Vendor SA Client/osmv_pfn_query_cb_t
 * NAME
 *	osmv_pfn_query_cb_t







More information about the general mailing list