kernel-fxtec-pro1x/net/ipv4
Yuchung Cheng 43876b1ce4 tcp: up initial rmem to 128KB and SYN rwin to around 64KB
[ Upstream commit a337531b942bd8a03e7052444d7e36972aac2d92 ]

Previously TCP initial receive buffer is ~87KB by default and
the initial receive window is ~29KB (20 MSS). This patch changes
the two numbers to 128KB and ~64KB (rounding down to the multiples
of MSS) respectively. The patch also simplifies the calculations s.t.
the two numbers are directly controlled by sysctl tcp_rmem[1]:

  1) Initial receiver buffer budget (sk_rcvbuf): while this should
     be configured via sysctl tcp_rmem[1], previously tcp_fixup_rcvbuf()
     always override and set a larger size when a new connection
     establishes.

  2) Initial receive window in SYN: previously it is set to 20
     packets if MSS <= 1460. The number 20 was based on the initial
     congestion window of 10: the receiver needs twice amount to
     avoid being limited by the receive window upon out-of-order
     delivery in the first window burst. But since this only
     applies if the receiving MSS <= 1460, connection using large MTU
     (e.g. to utilize receiver zero-copy) may be limited by the
     receive window.

With this patch TCP memory configuration is more straight-forward and
more properly sized to modern high-speed networks by default. Several
popular stacks have been announcing 64KB rwin in SYNs as well.

Signed-off-by: Yuchung Cheng <ycheng@google.com>
Signed-off-by: Wei Wang <weiwan@google.com>
Signed-off-by: Neal Cardwell <ncardwell@google.com>
Signed-off-by: Eric Dumazet <edumazet@google.com>
Reviewed-by: Soheil Hassas Yeganeh <soheil@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2019-11-24 08:19:23 +01:00
..
bpfilter
netfilter netfilter: masquerade: don't flush all conntracks if only one address deleted on device 2019-11-20 18:47:52 +01:00
af_inet.c
ah4.c
arp.c
cipso_ipv4.c net: avoid use IPCB in cipso_v4_error 2019-03-10 07:17:19 +01:00
datagram.c inet: stop leaking jiffies on the wire 2019-11-10 11:27:37 +01:00
devinet.c ipv4: don't set IPv6 only flags to IPv4 addresses 2019-07-28 08:29:23 +02:00
esp4.c esp4: add length check for UDP encapsulation 2019-05-25 18:23:41 +02:00
esp4_offload.c
fib_frontend.c ipv4: fix route update on metric change. 2019-11-10 11:27:50 +01:00
fib_lookup.h
fib_notifier.c
fib_rules.c
fib_semantics.c ipv4: Fix table id reference in fib_sync_down_addr 2019-11-12 19:20:27 +01:00
fib_trie.c net: ipv4: Fix memory leak in network namespace dismantle 2019-01-31 08:14:32 +01:00
fou.c net: fou: do not use guehdr after iptunnel_pull_offloads in gue_udp_recv 2019-04-27 09:36:31 +02:00
gre_demux.c ip_gre: fix parsing gre header in ipgre_err 2019-11-20 18:46:48 +01:00
gre_offload.c
icmp.c ipv4/icmp: fix rt dst dev null pointer dereference 2019-09-06 10:22:07 +02:00
igmp.c igmp: fix memory leak in igmpv3_del_delrec() 2019-07-28 08:29:23 +02:00
inet_connection_sock.c
inet_diag.c inet_diag: fix reporting cgroup classid and fallback to priority 2019-02-27 10:08:58 +01:00
inet_fragment.c net: IP defrag: encapsulate rbtree defrag code into callable functions 2019-04-27 09:36:33 +02:00
inet_hashtables.c net: annotate accesses to sk->sk_incoming_cpu 2019-11-10 11:27:38 +01:00
inet_timewait_sock.c
inetpeer.c net: ipv4: use a dedicated counter for icmp_v4 redirect packets 2019-02-23 09:07:24 +01:00
ip_forward.c
ip_fragment.c net: IP defrag: encapsulate rbtree defrag code into callable functions 2019-04-27 09:36:33 +02:00
ip_gre.c ip_gre: fix parsing gre header in ipgre_err 2019-11-20 18:46:48 +01:00
ip_input.c vrf: check accept_source_route on the original netdevice 2019-04-17 08:38:42 +02:00
ip_options.c vrf: check accept_source_route on the original netdevice 2019-04-17 08:38:42 +02:00
ip_output.c ipv4: ip_do_fragment: Preserve skb_iif during fragmentation 2019-05-05 14:42:36 +02:00
ip_sockglue.c
ip_tunnel.c
ip_tunnel_core.c ip_tunnel: allow not to count pkts on tstats by setting skb's dev to NULL 2019-08-04 09:30:57 +02:00
ip_vti.c vti4: ipip tunnel deregistration fixes. 2019-05-25 18:23:41 +02:00
ipcomp.c
ipconfig.c
ipip.c ipip: validate header length in ipip_tunnel_xmit 2019-08-09 17:52:30 +02:00
ipmr.c ipmr: Fix skb headroom in ipmr_get_route(). 2019-11-20 18:45:11 +01:00
ipmr_base.c
Kconfig
Makefile
metrics.c
netfilter.c
netlink.c ipv4: Add ICMPv6 support when parse route ipproto 2019-03-10 07:17:17 +01:00
ping.c
proc.c tcp: tcp_fragment() should apply sane memory limits 2019-06-17 19:51:56 +02:00
protocol.c
raw.c ipv4: Use return value of inet_iif() for __raw_v4_lookup in the while loop 2019-07-03 13:14:46 +02:00
raw_diag.c net: don't warn in inet diag when IPV6 is disabled 2019-10-01 08:26:11 +02:00
route.c ipv4: Return -ENETUNREACH if we can't create route but saddr is valid 2019-10-29 09:19:39 +01:00
syncookies.c tcp: handle inet_csk_reqsk_queue_add() failures 2019-03-19 13:12:39 +01:00
sysctl_net_ipv4.c tcp: add tcp_min_snd_mss sysctl 2019-06-17 19:51:56 +02:00
tcp.c tcp: up initial rmem to 128KB and SYN rwin to around 64KB 2019-11-24 08:19:23 +01:00
tcp_bbr.c
tcp_bic.c
tcp_cdg.c
tcp_cong.c tcp: fix tcp_set_congestion_control() use from bpf hook 2019-07-28 08:29:26 +02:00
tcp_cubic.c
tcp_dctcp.c tcp: Ensure DCTCP reacts to losses 2019-04-17 08:38:41 +02:00
tcp_diag.c
tcp_fastopen.c
tcp_highspeed.c
tcp_htcp.c
tcp_hybla.c
tcp_illinois.c
tcp_input.c tcp: up initial rmem to 128KB and SYN rwin to around 64KB 2019-11-24 08:19:23 +01:00
tcp_ipv4.c inet: stop leaking jiffies on the wire 2019-11-10 11:27:37 +01:00
tcp_lp.c
tcp_metrics.c
tcp_minisocks.c
tcp_nv.c
tcp_offload.c
tcp_output.c tcp: up initial rmem to 128KB and SYN rwin to around 64KB 2019-11-24 08:19:23 +01:00
tcp_rate.c
tcp_recovery.c
tcp_scalable.c
tcp_timer.c tcp: better handle TCP_USER_TIMEOUT in SYN_SENT state 2019-10-05 13:09:31 +02:00
tcp_ulp.c
tcp_vegas.c
tcp_vegas.h
tcp_veno.c
tcp_westwood.c
tcp_yeah.c
tunnel4.c
udp.c net: use skb_queue_empty_lockless() in poll() handlers 2019-11-10 11:27:48 +01:00
udp_diag.c
udp_impl.h
udp_offload.c
udp_tunnel.c
udplite.c
xfrm4_input.c
xfrm4_mode_beet.c
xfrm4_mode_transport.c
xfrm4_mode_tunnel.c
xfrm4_output.c
xfrm4_policy.c xfrm4: Fix uninitialized memory read in _decode_session4 2019-05-25 18:23:41 +02:00
xfrm4_protocol.c
xfrm4_state.c
xfrm4_tunnel.c