aboutsummaryrefslogtreecommitdiffstats
path: root/include/net/tcp.h
diff options
context:
space:
mode:
authorYuchung Cheng <ycheng@google.com>2017-01-13 01:11:32 -0500
committerDavid S. Miller <davem@davemloft.net>2017-01-13 22:37:16 -0500
commitdeed7be78f512d003c6290da0a781479b31b3d74 (patch)
treeac478434d723eb690fa62943f262c251d92a538c /include/net/tcp.h
parente636f8b0104d6622aaaed6aa5ef17dfbf165bc51 (diff)
tcp: record most recent RTT in RACK loss detection
Record the most recent RTT in RACK. It is often identical to the "ca_rtt_us" values in tcp_clean_rtx_queue. But when the packet has been retransmitted, RACK choses to believe the ACK is for the (latest) retransmitted packet if the RTT is over minimum RTT. This requires passing the arrival time of the most recent ACK to RACK routines. The timestamp is now recorded in the "ack_time" in tcp_sacktag_state during the ACK processing. This patch does not change the RACK algorithm itself. It only adds the RTT variable to prepare the next main patch. Signed-off-by: Yuchung Cheng <ycheng@google.com> Signed-off-by: Neal Cardwell <ncardwell@google.com> Acked-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/net/tcp.h')
-rw-r--r--include/net/tcp.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/include/net/tcp.h b/include/net/tcp.h
index 51183bba3835..1439107658c2 100644
--- a/include/net/tcp.h
+++ b/include/net/tcp.h
@@ -1863,9 +1863,10 @@ extern int sysctl_tcp_recovery;
1863/* Use TCP RACK to detect (some) tail and retransmit losses */ 1863/* Use TCP RACK to detect (some) tail and retransmit losses */
1864#define TCP_RACK_LOST_RETRANS 0x1 1864#define TCP_RACK_LOST_RETRANS 0x1
1865 1865
1866extern void tcp_rack_mark_lost(struct sock *sk); 1866extern void tcp_rack_mark_lost(struct sock *sk, const struct skb_mstamp *now);
1867extern void tcp_rack_advance(struct tcp_sock *tp, 1867extern void tcp_rack_advance(struct tcp_sock *tp, u8 sacked,
1868 const struct skb_mstamp *xmit_time, u8 sacked); 1868 const struct skb_mstamp *xmit_time,
1869 const struct skb_mstamp *ack_time);
1869 1870
1870/* 1871/*
1871 * Save and compile IPv4 options, return a pointer to it 1872 * Save and compile IPv4 options, return a pointer to it