[ofa-general] [PATCH] opensm/osm_qos_policy.c: log matched QoS criteria

Yevgeny Kliteynik kliteyn at dev.mellanox.co.il
Thu May 1 04:48:25 PDT 2008


Adding log messages for matched criteria of
the QoS policy rule.

Signed-off-by:  Yevgeny Kliteynik <kliteyn at dev.mellanox.co.il>
---
 opensm/opensm/osm_qos_policy.c |   18 +++++++++++++++---
 1 files changed, 15 insertions(+), 3 deletions(-)

diff --git a/opensm/opensm/osm_qos_policy.c b/opensm/opensm/osm_qos_policy.c
index 6c81872..185ccc0 100644
--- a/opensm/opensm/osm_qos_policy.c
+++ b/opensm/opensm/osm_qos_policy.c
@@ -624,6 +624,9 @@ static osm_qos_match_rule_t *__qos_policy_get_match_rule_by_params(
 				list_iterator = cl_list_next(list_iterator);
 				continue;
 			}
+			osm_log(&p_qos_policy->p_subn->p_osm->log, OSM_LOG_DEBUG,
+				"__qos_policy_get_match_rule_by_params: "
+				"Source port matched.\n");
 		}

 		/* If a match rule has Destination groups, PR request dest. has to be in this list */
@@ -637,6 +640,9 @@ static osm_qos_match_rule_t *__qos_policy_get_match_rule_by_params(
 				list_iterator = cl_list_next(list_iterator);
 				continue;
 			}
+			osm_log(&p_qos_policy->p_subn->p_osm->log, OSM_LOG_DEBUG,
+				"__qos_policy_get_match_rule_by_params: "
+				"Destination port matched.\n");
 		}

 		/* If a match rule has QoS classes, PR request HAS
@@ -655,7 +661,9 @@ static osm_qos_match_rule_t *__qos_policy_get_match_rule_by_params(
 				list_iterator = cl_list_next(list_iterator);
 				continue;
 			}
-
+			osm_log(&p_qos_policy->p_subn->p_osm->log, OSM_LOG_DEBUG,
+				"__qos_policy_get_match_rule_by_params: "
+				"QoS Class matched.\n");
 		}

 		/* If a match rule has Service IDs, PR request HAS
@@ -675,7 +683,9 @@ static osm_qos_match_rule_t *__qos_policy_get_match_rule_by_params(
 				list_iterator = cl_list_next(list_iterator);
 				continue;
 			}
-
+			osm_log(&p_qos_policy->p_subn->p_osm->log, OSM_LOG_DEBUG,
+				"__qos_policy_get_match_rule_by_params: "
+				"Service ID matched.\n");
 		}

 		/* If a match rule has PKeys, PR request HAS
@@ -694,7 +704,9 @@ static osm_qos_match_rule_t *__qos_policy_get_match_rule_by_params(
 				list_iterator = cl_list_next(list_iterator);
 				continue;
 			}
-
+			osm_log(&p_qos_policy->p_subn->p_osm->log, OSM_LOG_DEBUG,
+				"__qos_policy_get_match_rule_by_params: "
+				"PKey matched.\n");
 		}

 		/* if we got here, then this match-rule matched this PR request */
-- 
1.5.1.4




More information about the general mailing list