[ofa-general] [PATCH TRIVIAL] diags/mcm_rereg_test: more info messages

Sasha Khapyorsky sashak at voltaire.com
Mon Mar 5 10:25:53 PST 2007


Add more info messages. Change number of max clients.

Signed-off-by: Sasha Khapyorsky <sashak at voltaire.com>
---
 diags/src/mcm_rereg_test.c |   14 +++++++++++---
 1 files changed, 11 insertions(+), 3 deletions(-)

diff --git a/diags/src/mcm_rereg_test.c b/diags/src/mcm_rereg_test.c
index f0582a0..57c8db6 100644
--- a/diags/src/mcm_rereg_test.c
+++ b/diags/src/mcm_rereg_test.c
@@ -183,6 +183,8 @@ static int rereg_send_all(int port, int agent, ib_portid_t *dport,
 					       IB_MAD_TRID_F);
 	}
 
+	info("rereg_send_all: sent %u requests\n", cnt*2);
+
 	free(umad);
 
 	return 0;
@@ -245,7 +247,7 @@ static int rereg_recv_all(int port, int agent, ib_portid_t *dport,
 	uint8_t *umad, *mad;
 	int len = umad_size() + 256;
 	uint64_t trid;
-	unsigned method, status;
+	unsigned n, method, status;
 	int i;
 
 	info("rereg_recv_all...\n");
@@ -256,8 +258,10 @@ static int rereg_recv_all(int port, int agent, ib_portid_t *dport,
 		return -1;
 	}
 
+	n = 0;
 	while (rereg_recv(port, agent, dport, umad, len, TMO) > 0) {
-		dbg("rereg_recv_all: done %d\n", cnt++);
+		dbg("rereg_recv_all: done %d\n", n);
+		n++;
 		mad = umad_get_mad(umad);
 
 		method = mad_get_field(mad, 0, IB_MAD_METHOD_F);
@@ -286,6 +290,8 @@ static int rereg_recv_all(int port, int agent, ib_portid_t *dport,
 		}
 	}
 
+	info("rereg_recv_all: got %u responses\n", n);
+
 	free(umad);
 	return 0;
 }
@@ -330,6 +336,8 @@ static int rereg_query_all(int port, int agent, ib_portid_t *dport,
 			     ntohll(list[i].guid), status, method);
 	}
 
+	info("rereg_query_all: %u queried.\n", cnt);
+
 	free(umad);
 	return 0;
 }
@@ -370,7 +378,7 @@ static int rereg_mcm_rec_recv(int port, int agent, int cnt)
 }
 #endif
 
-#define MAX_CLIENTS 100
+#define MAX_CLIENTS 50
 
 static int rereg_and_test_port(char *guid_file, int port, int agent, ib_portid_t *dport, int timeout)
 {
-- 
1.5.0.1.40.gb40d




More information about the general mailing list