Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

tcp: delete redundant calls of tcp_mtup_init()

As tcp_rcv_state_process() has already calls tcp_mtup_init() for non-fastopen
sock, we can delete the redundant calls of tcp_mtup_init() in
tcp_{v4,v6}_syn_recv_sock().

Signed-off-by: Weiping Pan <panweiping3@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

authored by

Peter Pan(潘卫平) and committed by
David S. Miller
4d83e177 f0d4eb29

-2
-1
net/ipv4/tcp_ipv4.c
··· 1668 1668 } 1669 1669 sk_setup_caps(newsk, dst); 1670 1670 1671 - tcp_mtup_init(newsk); 1672 1671 tcp_sync_mss(newsk, dst_mtu(dst)); 1673 1672 newtp->advmss = dst_metric_advmss(dst); 1674 1673 if (tcp_sk(sk)->rx_opt.user_mss &&
-1
net/ipv6/tcp_ipv6.c
··· 1246 1246 inet_csk(newsk)->icsk_ext_hdr_len = (newnp->opt->opt_nflen + 1247 1247 newnp->opt->opt_flen); 1248 1248 1249 - tcp_mtup_init(newsk); 1250 1249 tcp_sync_mss(newsk, dst_mtu(dst)); 1251 1250 newtp->advmss = dst_metric_advmss(dst); 1252 1251 if (tcp_sk(sk)->rx_opt.user_mss &&