[netperf-dev] netperf2 commit notice r506 - trunk/src

raj at netperf.org raj at netperf.org
Wed Nov 30 16:03:53 PST 2011


Author: raj
Date: 2011-11-30 16:03:53 -0800 (Wed, 30 Nov 2011)
New Revision: 506

Modified:
   trunk/src/nettest_bsd.h
   trunk/src/nettest_omni.c
Log:
workup the remote congestion control

Modified: trunk/src/nettest_bsd.h
===================================================================
--- trunk/src/nettest_bsd.h	2011-11-29 00:19:36 UTC (rev 505)
+++ trunk/src/nettest_bsd.h	2011-12-01 00:03:53 UTC (rev 506)
@@ -129,7 +129,6 @@
 				name that long - and still didn't
 				include the 9NNN model number! */
   char       security_string[16];
-  char       cong_control[16]; /* what the congestion control alg was */
 };
 
 struct omni_results_struct {
@@ -169,6 +168,7 @@
   char       firmware[32];  
   char       bus[32];
   char       ifslot[16];    /* slot id of the probable egress interface */
+  char       cong_control[16]; /* what the congestion control alg was */
 
 };
 

Modified: trunk/src/nettest_omni.c
===================================================================
--- trunk/src/nettest_omni.c	2011-11-29 00:19:36 UTC (rev 505)
+++ trunk/src/nettest_omni.c	2011-12-01 00:03:53 UTC (rev 506)
@@ -3698,13 +3698,6 @@
 	remote_security_type = nsec_type_to_str(remote_security_type_id);
 	remote_security_enabled = 
 	  nsec_enabled_to_str(remote_security_enabled_num);
-	/* what was the congestion control? */
-	if (desired_output_groups & OMNI_WANT_REM_CONG) {
-	  strncpy(remote_cong_control,
-		  omni_response->cong_control,
-		  sizeof(remote_cong_control));
-	  remote_cong_control[sizeof(remote_cong_control) - 1] = '\0';
-	}
       }
       else {
 	Set_errno(netperf_response.content.serv_errno);
@@ -4348,6 +4341,13 @@
 	remote_interface_subvendor = omni_result->subvendor;
 	remote_interface_subdevice = omni_result->subdevice;
 	remote_transport_retrans = omni_result->transport_retrans;
+	/* what was the congestion control? */
+	if (desired_output_groups & OMNI_WANT_REM_CONG) {
+	  strncpy(remote_cong_control,
+		  omni_result->cong_control,
+		  sizeof(remote_cong_control));
+	  remote_cong_control[sizeof(remote_cong_control) - 1] = '\0';
+	}
       }
       else {
 	Set_errno(netperf_response.content.serv_errno);
@@ -4952,13 +4952,6 @@
 	  sizeof(omni_response->security_string));
   omni_response->security_string[sizeof(omni_response->security_string)-1] = 0;
 
-  if (omni_request->flags & OMNI_WANT_REM_CONG) {
-    get_transport_cong_control(s_listen,
-			       local_res->ai_protocol,
-			       omni_response->cong_control,
-			       sizeof(omni_response->cong_control));
-  }
-
   send_response_n(OMNI_RESPONSE_CONV_CUTOFF); /* brittle, but functional */
 
   local_send_calls = 0;
@@ -5362,7 +5355,17 @@
     strncpy(omni_results->firmware,"Bug If Seen DRVINFO",32);
     strncpy(omni_results->bus,"Bug If Seen DRVINFO",32);
   }
+  if (omni_request->flags & OMNI_WANT_REM_CONG) {
+    get_transport_cong_control(s_listen,
+			       local_res->ai_protocol,
+			       omni_results->cong_control,
+			       sizeof(omni_results->cong_control));
+  }
+  else {
+    strncpy(omni_results->cong_control,"",sizeof(omni_results->cong_control));
+  }
 
+
   if (debug) {
     fprintf(where,
 	    "recv_omni: test complete, sending results.\n");



More information about the netperf-dev mailing list