[openib-general] [PATCH][TRIVIAL] OpenSM/osm_sa_service_record.c: Some trivial cleanups
Hal Rosenstock
halr at voltaire.com
Wed Jul 19 08:32:49 PDT 2006
OpenSM/osm_sa_service_record.c: Some trivial cleanups
Assert on attribute ID where most common
Also, eliminate unused variable in osm_sr_rcv_process
Signed-off-by: Hal Rosenstock <halr at voltaire.com>
Index: opensm/osm_sa_service_record.c
===================================================================
--- opensm/osm_sa_service_record.c (revision 8589)
+++ opensm/osm_sa_service_record.c (working copy)
@@ -791,8 +791,6 @@ osm_sr_rcv_process_get_method(
p_recvd_service_rec =
(ib_service_record_t*)ib_sa_mad_get_payload_ptr( p_sa_mad );
- CL_ASSERT( p_sa_mad->attr_id == IB_MAD_ATTR_SERVICE_RECORD );
-
if( osm_log_is_active( p_rcv->p_log, OSM_LOG_DEBUG ) )
{
osm_dump_service_record( p_rcv->p_log,
@@ -1060,7 +1058,6 @@ osm_sr_rcv_process(
{
ib_sa_mad_t * p_sa_mad;
ib_net16_t sa_status = IB_SA_MAD_STATUS_REQ_INVALID;
- ib_service_record_t* p_recvd_service_rec;
boolean_t valid;
OSM_LOG_ENTER( p_rcv->p_log, osm_sr_rcv_process );
@@ -1068,8 +1065,8 @@ osm_sr_rcv_process(
CL_ASSERT( p_madw );
p_sa_mad = osm_madw_get_sa_mad_ptr( p_madw );
- p_recvd_service_rec =
- (ib_service_record_t*)ib_sa_mad_get_payload_ptr( p_sa_mad );
+
+ CL_ASSERT( p_sa_mad->attr_id == IB_MAD_ATTR_SERVICE_RECORD );
switch (p_sa_mad->method)
{
More information about the general
mailing list