diff options
author | Haishuang Yan <yanhaishuang@cmss.chinamobile.com> | 2017-09-27 06:35:43 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2017-10-02 03:55:54 +0300 |
commit | 3733be14a32bae288b61ed28341e593baba983af (patch) | |
tree | 972622b76e08246aee043832bdc8224f6ac50501 /include/net/netns/ipv4.h | |
parent | 437138485656c41e32b8c63c0987cfa0348be0e6 (diff) | |
download | linux-3733be14a32bae288b61ed28341e593baba983af.tar.xz |
ipv4: Namespaceify tcp_fastopen_blackhole_timeout knob
Different namespace application might require different time period in
second to disable Fastopen on active TCP sockets.
Tested:
Simulate following similar situation that the server's data gets dropped
after 3WHS.
C ---- syn-data ---> S
C <--- syn/ack ----- S
C ---- ack --------> S
S (accept & write)
C? X <- data ------ S
[retry and timeout]
And then print netstat of TCPFastOpenBlackhole, the counter increased as
expected when the firewall blackhole issue is detected and active TFO is
disabled.
# cat /proc/net/netstat | awk '{print $91}'
TCPFastOpenBlackhole
1
Signed-off-by: Haishuang Yan <yanhaishuang@cmss.chinamobile.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/net/netns/ipv4.h')
-rw-r--r-- | include/net/netns/ipv4.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/include/net/netns/ipv4.h b/include/net/netns/ipv4.h index 7bb9603ff66c..2c4222a5d102 100644 --- a/include/net/netns/ipv4.h +++ b/include/net/netns/ipv4.h @@ -133,6 +133,9 @@ struct netns_ipv4 { int sysctl_tcp_fastopen; struct tcp_fastopen_context __rcu *tcp_fastopen_ctx; spinlock_t tcp_fastopen_ctx_lock; + unsigned int sysctl_tcp_fastopen_blackhole_timeout; + atomic_t tfo_active_disable_times; + unsigned long tfo_active_disable_stamp; #ifdef CONFIG_NET_L3_MASTER_DEV int sysctl_udp_l3mdev_accept; |