CoDel AQM discussions
 help / color / mirror / Atom feed
From: Eric Dumazet <eric.dumazet@gmail.com>
To: Richard Scheffenegger <rscheff@gmx.at>
Cc: codel@lists.bufferbloat.net
Subject: Re: [Codel] [RFC PATCH] codel: ecn mark at target
Date: Mon, 06 Aug 2012 18:46:19 +0200	[thread overview]
Message-ID: <1344271579.26674.45.camel@edumazet-glaptop> (raw)
In-Reply-To: <8860AEB6C5DB43649852D9A8B40E9B9F@srichardlxp2>

On Mon, 2012-08-06 at 18:22 +0200, Richard Scheffenegger wrote:
> Well, as long as the window is large enough, the delayed ACKs shouldn't 
> matter, even if the ECE is delayed for 1 segment; the argument about delayed 
> ACKs when cwnd is 1 is also true for non-ECN flows; they would run better 
> when every segment is acked individually; but can the receiver tell, if the 
> sender is running at cwnd=1?
> 

It should just be safe instead than lazy.

Frankly what's the deal to send an ACK right now instead of in 40ms ?

> Perhaps, if it tracks the RTT of the flow (which has to work without TS, as 
> they are undefined for pure ACKs), and the number of segments seen during 
> one RTT...

Linux does have an heuristic to _not_ use delayed acks for the first
packets received (about 15 MSS), _because_ it assumes sender has a small
cwnd.

When receiving out of order packets, this logic is restarted, because we
want to send SACKS as soon as possible, not after a delayed ack.

Every time we suspect sender has a small cwnd, we enter the quickack
mode.

So when receiving CE segments, we should do the same. Thats a flaw in
current linux code to do nothing and expect more packets to come.

It just works because RTO triggers. A lot of bugs are hidden because of
various timers that take some emergency actions.

tcp_enter_quickack_mode() has all the needed tweaks.


diff --git a/net/ipv4/tcp_input.c b/net/ipv4/tcp_input.c
index 2fd2bc9..2e55337 100644
--- a/net/ipv4/tcp_input.c
+++ b/net/ipv4/tcp_input.c
@@ -237,6 +237,9 @@ static inline void TCP_ECN_check_ce(struct tcp_sock *tp, const struct sk_buff *s
 			tcp_enter_quickack_mode((struct sock *)tp);
 		break;
 	case INET_ECN_CE:
+		/* Better not delay acks, sender can have a very low cwnd */
+		tcp_enter_quickack_mode((struct sock *)tp);
+
 		tp->ecn_flags |= TCP_ECN_DEMAND_CWR;
 		/* fallinto */
 	default:



  reply	other threads:[~2012-08-06 16:46 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-08-04  2:44 Dave Täht
2012-08-04  6:45 ` Eric Dumazet
2012-08-04 21:53   ` Kathleen Nichols
2012-08-05  3:06     ` Andrew McGregor
2012-08-05  5:30       ` Eric Dumazet
2012-08-05 16:53         ` Andrew McGregor
2012-08-05 16:58           ` Kathleen Nichols
2012-08-05 17:14             ` Andrew McGregor
2012-08-05 17:15           ` Eric Dumazet
2012-08-05 16:54         ` Richard Scheffenegger
2012-08-05 17:25           ` Eric Dumazet
2012-08-05 17:35             ` Eric Dumazet
2012-08-05 18:14               ` Yuchung Cheng
2012-08-05 18:40                 ` Eric Dumazet
2012-08-05 19:49                   ` Eric Dumazet
2012-08-06 16:22                   ` Richard Scheffenegger
2012-08-06 16:46                     ` Eric Dumazet [this message]
2012-08-06 17:50                       ` Dave Taht
2012-08-06 19:09                         ` Andrew McGregor
2012-08-06 20:01                           ` Eric Dumazet
2012-08-10 17:48                             ` Dave Taht
2012-08-04  7:00 ` Roger Jørgensen
2012-08-04 13:38   ` Richard Scheffenegger
2012-08-04 17:21     ` Eric Dumazet

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

  List information: https://lists.bufferbloat.net/postorius/lists/codel.lists.bufferbloat.net/

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

  git send-email \
    --in-reply-to=1344271579.26674.45.camel@edumazet-glaptop \
    --to=eric.dumazet@gmail.com \
    --cc=codel@lists.bufferbloat.net \
    --cc=rscheff@gmx.at \
    /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