|
|
@@ -1187,13 +1187,6 @@ int tcp_sendmsg(struct kiocb *iocb, struct sock *sk, struct msghdr *msg,
|
|
|
if (!skb)
|
|
|
goto wait_for_memory;
|
|
|
|
|
|
- /*
|
|
|
- * All packets are restored as if they have
|
|
|
- * already been sent.
|
|
|
- */
|
|
|
- if (tp->repair)
|
|
|
- TCP_SKB_CB(skb)->when = tcp_time_stamp;
|
|
|
-
|
|
|
/*
|
|
|
* Check whether we can use HW checksum.
|
|
|
*/
|
|
|
@@ -1203,6 +1196,13 @@ int tcp_sendmsg(struct kiocb *iocb, struct sock *sk, struct msghdr *msg,
|
|
|
skb_entail(sk, skb);
|
|
|
copy = size_goal;
|
|
|
max = size_goal;
|
|
|
+
|
|
|
+ /* All packets are restored as if they have
|
|
|
+ * already been sent. skb_mstamp isn't set to
|
|
|
+ * avoid wrong rtt estimation.
|
|
|
+ */
|
|
|
+ if (tp->repair)
|
|
|
+ TCP_SKB_CB(skb)->sacked |= TCPCB_REPAIRED;
|
|
|
}
|
|
|
|
|
|
/* Try to append data to the end of skb. */
|