From 5b4956138173cb8b58d83d3173360e8e681a2b66 Mon Sep 17 00:00:00 2001 From: Thomas Young Date: Tue, 6 Dec 2005 16:16:34 -0800 Subject: [PATCH] [TCP] Vegas: stop resetting rtt every ack Move the resetting of rtt measurements to inside the once per RTT block of code. Signed-off-by: Thomas Young Signed-off-by: David S. Miller --- net/ipv4/tcp_vegas.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/net/ipv4/tcp_vegas.c b/net/ipv4/tcp_vegas.c index b7d296a8ac6..8f06a479305 100644 --- a/net/ipv4/tcp_vegas.c +++ b/net/ipv4/tcp_vegas.c @@ -333,11 +333,11 @@ static void tcp_vegas_cong_avoid(struct sock *sk, u32 ack, else if (tp->snd_cwnd > tp->snd_cwnd_clamp) tp->snd_cwnd = tp->snd_cwnd_clamp; } - } - /* Wipe the slate clean for the next RTT. */ - vegas->cntRTT = 0; - vegas->minRTT = 0x7fffffff; + /* Wipe the slate clean for the next RTT. */ + vegas->cntRTT = 0; + vegas->minRTT = 0x7fffffff; + } } /* Extract info for Tcp socket info provided via netlink. */ -- 2.20.1