aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet/tcp
diff options
context:
space:
mode:
authorFlorin Coras <fcoras@cisco.com>2019-10-22 13:34:30 -0700
committerAndrew Yourtchenko <ayourtch@gmail.com>2019-11-05 10:41:16 +0000
commit6de46b40d2d2429e8f4f06272536fb5535c73908 (patch)
treecc37eda6f42be284e1372e142cad31236adc8e1b /src/vnet/tcp
parent7def5ba81592d3c46f4da0c116f50bfe190928fe (diff)
tcp: track lost rxt segments in byte tracker
Type: feature Change-Id: I18dfac9c3d2f539edf20dba64cd2b7b541154144 Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit 46ec6e018e95a10d46d018dbc15d90c309b5dccc)
Diffstat (limited to 'src/vnet/tcp')
-rw-r--r--src/vnet/tcp/tcp.h1
-rw-r--r--src/vnet/tcp/tcp_bt.c4
2 files changed, 5 insertions, 0 deletions
diff --git a/src/vnet/tcp/tcp.h b/src/vnet/tcp/tcp.h
index 657f1bea449..be8d38770d5 100644
--- a/src/vnet/tcp/tcp.h
+++ b/src/vnet/tcp/tcp.h
@@ -256,6 +256,7 @@ typedef enum tcp_bts_flags_
TCP_BTS_IS_RXT = 1,
TCP_BTS_IS_APP_LIMITED = 1 << 1,
TCP_BTS_IS_SACKED = 1 << 2,
+ TCP_BTS_IS_RXT_LOST = 1 << 3,
} __clib_packed tcp_bts_flags_t;
typedef struct tcp_bt_sample_
diff --git a/src/vnet/tcp/tcp_bt.c b/src/vnet/tcp/tcp_bt.c
index b3f4e6ab000..e8cf0680d4d 100644
--- a/src/vnet/tcp/tcp_bt.c
+++ b/src/vnet/tcp/tcp_bt.c
@@ -368,6 +368,8 @@ tcp_bt_track_rxt (tcp_connection_t * tc, u32 start, u32 end)
cur = tcp_bt_alloc_tx_sample (tc, start, end);
cur->flags |= TCP_BTS_IS_RXT;
+ if (bts->flags & TCP_BTS_IS_RXT)
+ cur->flags |= TCP_BTS_IS_RXT_LOST;
cur->next = next_index;
cur->prev = prev_index;
@@ -408,6 +410,8 @@ tcp_bt_track_rxt (tcp_connection_t * tc, u32 start, u32 end)
/* Have to split or tail overlap */
cur = tcp_bt_alloc_tx_sample (tc, start, end);
cur->flags |= TCP_BTS_IS_RXT;
+ if (bts->flags & TCP_BTS_IS_RXT)
+ cur->flags |= TCP_BTS_IS_RXT_LOST;
cur->prev = bts_index;
cur_index = bt_sample_index (bt, cur);