diff mbox

[2/3] osm_congestion_control.c: Consistently set cc_unavailable_flag

Message ID 1419291134.21271.15.camel@auk59.llnl.gov (mailing list archive)
State Accepted
Delegated to: Hal Rosenstock
Headers show

Commit Message

Al Chu Dec. 22, 2014, 11:32 p.m. UTC
For consistency to other code, set flag using TRUE and FALSE macros.

Signed-off-by: Albert L. Chu <chu11@llnl.gov>
---
 opensm/osm_congestion_control.c |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

Comments

Hal Rosenstock Jan. 5, 2015, 8:51 p.m. UTC | #1
On 12/22/2014 6:32 PM, Albert Chu wrote:
> For consistency to other code, set flag using TRUE and FALSE macros.
> 
> Signed-off-by: Albert L. Chu <chu11@llnl.gov>

Thanks. Applied.

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

Patch

diff --git a/opensm/osm_congestion_control.c b/opensm/osm_congestion_control.c
index 0612ba1..54574b7 100644
--- a/opensm/osm_congestion_control.c
+++ b/opensm/osm_congestion_control.c
@@ -482,12 +482,12 @@  static void cc_rcv_mad(void *context, void *data)
 		if (p_cc_mad->header.status & IB_MAD_STATUS_UNSUP_CLASS_VER
 		    || p_cc_mad->header.status & IB_MAD_STATUS_UNSUP_METHOD
 		    || p_cc_mad->header.status & IB_MAD_STATUS_UNSUP_METHOD_ATTR)
-			p_port->cc_unavailable_flag = 1;
+			p_port->cc_unavailable_flag = TRUE;
 		cl_plock_release(&p_osm->lock);
 		goto Exit;
 	}
 	else
-		p_port->cc_unavailable_flag = 0;
+		p_port->cc_unavailable_flag = FALSE;
 
 	if (p_cc_mad->header.attr_id == IB_MAD_ATTR_SW_CONG_SETTING) {
 		ib_sw_cong_setting_t *p_sw_cong_setting;
@@ -706,7 +706,7 @@  static void cc_mad_send_err_callback(void *bind_context,
 		p_port->cc_timeout_count++;
 		if (p_port->cc_timeout_count > OSM_CC_TIMEOUT_COUNT_THRESHOLD
 		    && !p_port->cc_unavailable_flag)
-			p_port->cc_unavailable_flag++;
+			p_port->cc_unavailable_flag = TRUE;
 	} else
 		p_cc->subn->subnet_initialization_error = TRUE;