Skip to content

Commit 737ff31

Browse files
yuchungchengdavem330
authored andcommitted
tcp: use sequence distance to detect reordering
Replace the reordering distance measurement in packet unit with sequence based approach. Previously it trackes the number of "packets" toward the forward ACK (i.e. highest sacked sequence)in a state variable "fackets_out". Precisely measuring reordering degree on packet distance has not much benefit, as the degree constantly changes by factors like path, load, and congestion window. It is also complicated and prone to arcane bugs. This patch replaces with sequence-based approach that's much simpler. Signed-off-by: Yuchung Cheng <ycheng@google.com> Reviewed-by: Eric Dumazet <edumazet@google.com> Reviewed-by: Neal Cardwell <ncardwell@google.com> Reviewed-by: Soheil Hassas Yeganeh <soheil@google.com> Reviewed-by: Priyaranjan Jha <priyarjha@google.com> Signed-off-by: David S. Miller <davem@davemloft.net>
1 parent 713bafe commit 737ff31

5 files changed

Lines changed: 68 additions & 107 deletions

File tree

‎include/linux/tcp.h‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -293,7 +293,6 @@ struct tcp_sock {
293293
u32 pushed_seq; /* Last pushed seq, required to talk to windows */
294294
u32 lost_out; /* Lost packets */
295295
u32 sacked_out; /* SACK'd packets */
296-
u32 fackets_out; /* FACK'd packets */
297296

298297
struct hrtimer pacing_timer;
299298

‎net/ipv4/tcp.c‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2977,7 +2977,6 @@ void tcp_get_info(struct sock *sk, struct tcp_info *info)
29772977

29782978
info->tcpi_lost = tp->lost_out;
29792979
info->tcpi_retrans = tp->retrans_out;
2980-
info->tcpi_fackets = tp->fackets_out;
29812980

29822981
now = tcp_jiffies32;
29832982
info->tcpi_last_data_sent = jiffies_to_msecs(now - tp->lsndtime);

0 commit comments

Comments
 (0)