aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet/tcp/tcp.c
diff options
context:
space:
mode:
authorFlorin Coras <fcoras@cisco.com>2017-11-27 04:34:14 -0500
committerDave Barach <openvpp@barachs.net>2017-11-28 13:21:26 +0000
commitf988e696149f42828444c69762c036d9684b6bb0 (patch)
tree8e62fbd53a713e64be7c0441f0399aa023a949d8 /src/vnet/tcp/tcp.c
parentaf6f93a4eb4740ac13b1d65eb44da442976fa809 (diff)
tcp: fix retransmissions under buffer shortage
- add debugging scaffolding for simulating buffer shortage Change-Id: Ice519d74f9c4e4094c4586c548185135b7bb5f2d Signed-off-by: Florin Coras <fcoras@cisco.com>
Diffstat (limited to 'src/vnet/tcp/tcp.c')
-rw-r--r--src/vnet/tcp/tcp.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/vnet/tcp/tcp.c b/src/vnet/tcp/tcp.c
index a0a5f190fa4..b16b2a7dfb2 100644
--- a/src/vnet/tcp/tcp.c
+++ b/src/vnet/tcp/tcp.c
@@ -233,6 +233,8 @@ tcp_connection_reset (tcp_connection_t * tc)
tcp_connection_cleanup (tc);
break;
case TCP_STATE_ESTABLISHED:
+ stream_session_reset_notify (&tc->connection);
+ /* fall through */
case TCP_STATE_CLOSE_WAIT:
case TCP_STATE_FIN_WAIT_1:
case TCP_STATE_FIN_WAIT_2:
@@ -242,7 +244,6 @@ tcp_connection_reset (tcp_connection_t * tc)
/* Make sure all timers are cleared */
tcp_connection_timers_reset (tc);
- stream_session_reset_notify (&tc->connection);
/* Wait for cleanup from session layer but not forever */
tcp_timer_update (tc, TCP_TIMER_WAITCLOSE, TCP_CLEANUP_TIME);
@@ -1319,7 +1320,9 @@ tcp_config_fn (vlib_main_t * vm, unformat_input_t * input)
&tm->local_endpoints_table_buckets))
;
-
+ else if (unformat (input, "buffer-fail-fraction %f",
+ &tm->buffer_fail_fraction))
+ ;
else
return clib_error_return (0, "unknown input `%U'",
format_unformat_error, input);