svn commit: r188852 - head/sys/netinet

Randall Stewart rrs at FreeBSD.org
Fri Feb 20 06:33:46 PST 2009


Author: rrs
Date: Fri Feb 20 14:33:45 2009
New Revision: 188852
URL: http://svn.freebsd.org/changeset/base/188852

Log:
  Fix a bug. The sending was being restricted improperly by
  the max_burst. It should only be gated by cwnd in the
  lower level send.
  
  Obtained from:	Michael Tuexen
  MFC after:	1 week.

Modified:
  head/sys/netinet/sctp_output.c

Modified: head/sys/netinet/sctp_output.c
==============================================================================
--- head/sys/netinet/sctp_output.c	Fri Feb 20 14:28:56 2009	(r188851)
+++ head/sys/netinet/sctp_output.c	Fri Feb 20 14:33:45 2009	(r188852)
@@ -15014,7 +15014,7 @@ skip_preblock:
 			} else {
 				un_sent = ((stcb->asoc.total_output_queue_size - stcb->asoc.total_flight) +
 				    (stcb->asoc.stream_queue_cnt * sizeof(struct sctp_data_chunk)));
-				if (net->flight_size > (net->mtu * stcb->asoc.max_burst)) {
+				if (net->flight_size > net->cwnd) {
 					queue_only = 1;
 					SCTP_STAT_INCR(sctps_send_burst_avoid);
 				} else if (net->flight_size > net->cwnd) {
@@ -15291,7 +15291,7 @@ skip_out_eof:
 	} else {
 		un_sent = ((stcb->asoc.total_output_queue_size - stcb->asoc.total_flight) +
 		    (stcb->asoc.stream_queue_cnt * sizeof(struct sctp_data_chunk)));
-		if (net->flight_size > (net->mtu * stcb->asoc.max_burst)) {
+		if (net->flight_size > net->cwnd) {
 			queue_only = 1;
 			SCTP_STAT_INCR(sctps_send_burst_avoid);
 		} else if (net->flight_size > net->cwnd) {


More information about the svn-src-head mailing list