Netdev List
 help / color / mirror / Atom feed
From: Stephen Hemminger <shemminger@osdl.org>
To: "Xiaoliang (David) Wei" <davidwei79@gmail.com>,
	John Heffner <jheffner@psc.edu>
Cc: netdev@vger.kernel.org
Subject: Re: The AI parameter of tcp_highspeed.c (in 2.6.18)
Date: Fri, 2 Jun 2006 12:05:07 -0700	[thread overview]
Message-ID: <20060602120507.7e1206d8@dxpl.pdx.osdl.net> (raw)
In-Reply-To: <7335583a0605292112l1f5a6ec3x4b1c1e4ae45688f5@mail.gmail.com>

Went backed and looked at the RFC. The problem was just a simple
translation of table to C array (0 based). Added this to the TCP testing repository.

Subject: [PATCH] Problem observed by Xiaoliang (David) Wei:

  When snd_cwnd is smaller than 38 and the connection is in
  congestion avoidance phase (snd_cwnd > snd_ssthresh), the snd_cwnd
  seems to stop growing.

The additive increase was confused because C array's are 0 based.

Signed-off-by: Stephen Hemminger <shemminger@osdl.org>

---

 net/ipv4/tcp_highspeed.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

121685b7b61c8faeb87e6c6f0c346b0fe1c46fd2
diff --git a/net/ipv4/tcp_highspeed.c b/net/ipv4/tcp_highspeed.c
index b72fa55..ba7c63c 100644
--- a/net/ipv4/tcp_highspeed.c
+++ b/net/ipv4/tcp_highspeed.c
@@ -135,7 +135,8 @@ static void hstcp_cong_avoid(struct sock
 
 		/* Do additive increase */
 		if (tp->snd_cwnd < tp->snd_cwnd_clamp) {
-			tp->snd_cwnd_cnt += ca->ai;
+			/* cwnd = cwnd + a(w) / cwnd */
+			tp->snd_cwnd_cnt += ca->ai + 1;
 			if (tp->snd_cwnd_cnt >= tp->snd_cwnd) {
 				tp->snd_cwnd_cnt -= tp->snd_cwnd;
 				tp->snd_cwnd++;
-- 
1.3.3


  reply	other threads:[~2006-06-02 19:05 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-05-30  4:12 The AI parameter of tcp_highspeed.c (in 2.6.18) Xiaoliang (David) Wei
2006-06-02 19:05 ` Stephen Hemminger [this message]
2006-06-03  0:51   ` David Miller
2006-06-12 17:10   ` Xiaoliang (David) Wei

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20060602120507.7e1206d8@dxpl.pdx.osdl.net \
    --to=shemminger@osdl.org \
    --cc=davidwei79@gmail.com \
    --cc=jheffner@psc.edu \
    --cc=netdev@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox