diff options
Diffstat (limited to 'net/ipv4/tcp_yeah.h')
-rw-r--r-- | net/ipv4/tcp_yeah.h | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/net/ipv4/tcp_yeah.h b/net/ipv4/tcp_yeah.h index a62d82038fd0..33ad5385c188 100644 --- a/net/ipv4/tcp_yeah.h +++ b/net/ipv4/tcp_yeah.h | |||
@@ -81,10 +81,13 @@ static void tcp_vegas_state(struct sock *sk, u8 ca_state) | |||
81 | * o min-filter RTT samples from a much longer window (forever for now) | 81 | * o min-filter RTT samples from a much longer window (forever for now) |
82 | * to find the propagation delay (baseRTT) | 82 | * to find the propagation delay (baseRTT) |
83 | */ | 83 | */ |
84 | static void tcp_vegas_rtt_calc(struct sock *sk, u32 usrtt) | 84 | static void tcp_vegas_pkts_acked(struct sock *sk, u32 cnt, ktime_t last) |
85 | { | 85 | { |
86 | struct vegas *vegas = inet_csk_ca(sk); | 86 | struct vegas *vegas = inet_csk_ca(sk); |
87 | u32 vrtt = usrtt + 1; /* Never allow zero rtt or baseRTT */ | 87 | u32 vrtt; |
88 | |||
89 | /* Never allow zero rtt or baseRTT */ | ||
90 | vrtt = (ktime_to_ns(net_timedelta(last)) / NSEC_PER_USEC) + 1; | ||
88 | 91 | ||
89 | /* Filter to find propagation delay: */ | 92 | /* Filter to find propagation delay: */ |
90 | if (vrtt < vegas->baseRTT) | 93 | if (vrtt < vegas->baseRTT) |