From: Mao Wenan Date: Thu, 2 Jan 2020 14:02:27 +0000 (+0800) Subject: tcp: use REXMIT_NEW instead of magic number X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=d0e8bcafc8aff5553beffe55046795f9bab9fe7b;p=openwrt%2Fstaging%2Fblogic.git tcp: use REXMIT_NEW instead of magic number REXMIT_NEW is a macro for "FRTO-style transmit of unsent/new packets", this patch makes it more readable. Signed-off-by: Mao Wenan Acked-by: Neal Cardwell Signed-off-by: David S. Miller --- diff --git a/net/ipv4/tcp_input.c b/net/ipv4/tcp_input.c index 88b987ca9ebb..1d1e3493965f 100644 --- a/net/ipv4/tcp_input.c +++ b/net/ipv4/tcp_input.c @@ -3550,7 +3550,7 @@ static void tcp_xmit_recovery(struct sock *sk, int rexmit) if (rexmit == REXMIT_NONE || sk->sk_state == TCP_SYN_SENT) return; - if (unlikely(rexmit == 2)) { + if (unlikely(rexmit == REXMIT_NEW)) { __tcp_push_pending_frames(sk, tcp_current_mss(sk), TCP_NAGLE_OFF); if (after(tp->snd_nxt, tp->high_seq))