public inbox for linux-rdma@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] opensm/osm_sm_state_mgr.c: Cosmetic formatting changes
@ 2009-10-19 13:03 Hal Rosenstock
       [not found] ` <20091019130351.GC18483-Wuw85uim5zDR7s880joybQ@public.gmane.org>
  0 siblings, 1 reply; 2+ messages in thread
From: Hal Rosenstock @ 2009-10-19 13:03 UTC (permalink / raw)
  To: sashak-smomgflXvOZWk0Htik3J/w; +Cc: linux-rdma-u79uwXL29TY76Z2rM5mHXA


Signed-off-by: Hal Rosenstock <hal.rosenstock-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
---
diff --git a/opensm/opensm/osm_sm_state_mgr.c b/opensm/opensm/osm_sm_state_mgr.c
index d06e6aa..f046447 100644
--- a/opensm/opensm/osm_sm_state_mgr.c
+++ b/opensm/opensm/osm_sm_state_mgr.c
@@ -86,15 +86,17 @@ static void sm_state_mgr_send_master_sm_info_req(osm_sm_t * sm)
 	memset(&context, 0, sizeof(context));
 	if (sm->p_subn->sm_state == IB_SMINFO_STATE_STANDBY) {
 		/*
-		 * We are in STANDBY state - this means we need to poll on the master
-		 * SM (according to master_guid)
-		 * Send a query of SubnGet(SMInfo) to the subn master_sm_base_lid object.
+		 * We are in STANDBY state - this means we need to poll the
+		 * master SM (according to master_guid).
+		 * Send a query of SubnGet(SMInfo) to the subn
+		 * master_sm_base_lid object.
 		 */
 		p_port = osm_get_port_by_guid(sm->p_subn, sm->master_sm_guid);
 	} else {
 		/*
-		 * We are not in STANDBY - this means we are in MASTER state - so we need
-		 * to poll on the SM that is saved in p_polling_sm under sm.
+		 * We are not in STANDBY - this means we are in MASTER state -
+		 * so we need to poll the SM that is saved in p_polling_sm
+		 * under sm.
 		 * Send a query of SubnGet(SMInfo) to that SM.
 		 */
 		p_port = sm->p_polling_sm->p_port;
@@ -338,8 +340,10 @@ ib_api_status_t osm_sm_state_mgr_process(osm_sm_t * sm,
 			 */
 			/* Turn on the first_time_master_sweep flag */
 			sm->p_subn->first_time_master_sweep = TRUE;
-			/* Turn on the force_heavy_sweep - we want a
-			 * heavy sweep to occur on the first sweep of this SM. */
+			/*
+			 * Turn on the force_heavy_sweep - we want a
+			 * heavy sweep to occur on the first sweep of this SM.
+			 */
 			sm->p_subn->force_heavy_sweep = TRUE;
 
 			sm->p_subn->sm_state = IB_SMINFO_STATE_MASTER;
@@ -387,24 +391,28 @@ ib_api_status_t osm_sm_state_mgr_process(osm_sm_t * sm,
 		switch (signal) {
 		case OSM_SM_SIGNAL_POLLING_TIMEOUT:
 			/*
-			 * we received a polling timeout - this means that we waited for
-			 * a remote master sm to send us a handover, but didn't get it, and
-			 * didn't get a response from that remote sm.
-			 * We want to force a heavy sweep - hopefully this occurred because
-			 * the remote sm died, and we'll find this out and configure the
-			 * subnet after a heavy sweep.
-			 * We also want to clear the p_polling_sm object - since we are
-			 * done polling on that remote sm - we are sweeping again.
+			 * We received a polling timeout - this means that we
+			 * waited for a remote master sm to send us a handover,
+			 * but didn't get it, and didn't get a response from
+			 * that remote sm.
+			 * We want to force a heavy sweep - hopefully this
+			 * occurred because the remote sm died, and we'll find
+			 * this out and configure the subnet after a heavy sweep.
+			 * We also want to clear the p_polling_sm object - since
+			 * we are done polling on that remote sm - we are
+			 * sweeping again.
 			 */
 		case OSM_SM_SIGNAL_HANDOVER:
 			/*
-			 * If we received a handover in a master state - then we want to
-			 * force a heavy sweep. This means that either we are in a sweep
-			 * currently - in this case - no change, or we are in idle state -
-			 * since we recognized a master SM before - so we want to make a
+			 * If we received a handover in a master state - then we
+			 * want to force a heavy sweep. This means that either
+			 * we are in a sweep currently - in this case - no
+			 * change, or we are in idle state - since we
+			 * recognized a master SM before - so we want to make a
 			 * heavy sweep and reconfigure the new subnet.
-			 * We also want to clear the p_polling_sm object - since we are
-			 * done polling on that remote sm - we got a handover from it.
+			 * We also want to clear the p_polling_sm object - since
+			 * we are done polling on that remote sm - we got a
+			 * handover from it.
 			 */
 			OSM_LOG(sm->p_log, OSM_LOG_VERBOSE,
 				"Forcing heavy sweep. "
@@ -424,11 +432,11 @@ ib_api_status_t osm_sm_state_mgr_process(osm_sm_t * sm,
 			break;
 		case OSM_SM_SIGNAL_WAIT_FOR_HANDOVER:
 			/*
-			 * We found a remote master SM, and we are waiting for it
-			 * to handover the mastership to us. Need to start polling
-			 * on that SM, to make sure it is alive, if it isn't - then
-			 * we should move back to discovering, since something must
-			 * have happened to it.
+			 * We found a remote master SM, and we are waiting for
+			 * it to handover the mastership to us. Need to start
+			 * polling that SM, to make sure it is alive, if it
+			 * isn't - then we should move back to discovering,
+			 * since something must have happened to it.
 			 */
 			sm_state_mgr_start_polling(sm);
 			break;
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] opensm/osm_sm_state_mgr.c: Cosmetic formatting changes
       [not found] ` <20091019130351.GC18483-Wuw85uim5zDR7s880joybQ@public.gmane.org>
@ 2009-10-22 12:15   ` Sasha Khapyorsky
  0 siblings, 0 replies; 2+ messages in thread
From: Sasha Khapyorsky @ 2009-10-22 12:15 UTC (permalink / raw)
  To: Hal Rosenstock; +Cc: linux-rdma-u79uwXL29TY76Z2rM5mHXA

On 09:03 Mon 19 Oct     , Hal Rosenstock wrote:
> 
> Signed-off-by: Hal Rosenstock <hal.rosenstock-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>

Applied. Thanks.

Sasha
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2009-10-22 12:15 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-10-19 13:03 [PATCH] opensm/osm_sm_state_mgr.c: Cosmetic formatting changes Hal Rosenstock
     [not found] ` <20091019130351.GC18483-Wuw85uim5zDR7s880joybQ@public.gmane.org>
2009-10-22 12:15   ` Sasha Khapyorsky

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox