Code Review
/
vpp.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
tcp: cc improvements and fixes
[vpp.git]
/
src
/
vnet
/
tcp
/
tcp_output.c
diff --git
a/src/vnet/tcp/tcp_output.c
b/src/vnet/tcp/tcp_output.c
index
5932ed4
..
2745065
100644
(file)
--- a/
src/vnet/tcp/tcp_output.c
+++ b/
src/vnet/tcp/tcp_output.c
@@
-163,8
+163,8
@@
tcp_update_rcv_wnd (tcp_connection_t * tc)
/*
* Figure out how much space we have available
*/
/*
* Figure out how much space we have available
*/
- available_space =
stream_session
_max_rx_enqueue (&tc->connection);
- max_fifo =
stream_session
_rx_fifo_size (&tc->connection);
+ available_space =
transport
_max_rx_enqueue (&tc->connection);
+ max_fifo =
transport
_rx_fifo_size (&tc->connection);
ASSERT (tc->rcv_opts.mss < max_fifo);
if (available_space < tc->rcv_opts.mss && available_space < max_fifo >> 3)
ASSERT (tc->rcv_opts.mss < max_fifo);
if (available_space < tc->rcv_opts.mss && available_space < max_fifo >> 3)
@@
-1347,10
+1347,12
@@
tcp_rtx_timeout_cc (tcp_connection_t * tc)
tcp_cc_fastrecovery_exit (tc);
/* Start again from the beginning */
tcp_cc_fastrecovery_exit (tc);
/* Start again from the beginning */
- tc->
ssthresh = clib_max (tcp_flight_size (tc) / 2, 2 * tc->snd_mss
);
+ tc->
cc_algo->congestion (tc
);
tc->cwnd = tcp_loss_wnd (tc);
tc->snd_congestion = tc->snd_una_max;
tc->rtt_ts = 0;
tc->cwnd = tcp_loss_wnd (tc);
tc->snd_congestion = tc->snd_una_max;
tc->rtt_ts = 0;
+ tc->cwnd_acc_bytes = 0;
+
tcp_recovery_on (tc);
}
tcp_recovery_on (tc);
}
@@
-1393,7
+1395,7
@@
tcp_timer_retransmit_handler_i (u32 index, u8 is_syn)
}
/* Shouldn't be here */
}
/* Shouldn't be here */
- if (
tc->snd_una == tc->snd_una_max
)
+ if (
seq_geq (tc->snd_una, tc->snd_congestion)
)
{
tcp_recovery_off (tc);
return;
{
tcp_recovery_off (tc);
return;
@@
-1414,7
+1416,7
@@
tcp_timer_retransmit_handler_i (u32 index, u8 is_syn)
if (tc->rto_boff == 1)
tcp_rtx_timeout_cc (tc);
if (tc->rto_boff == 1)
tcp_rtx_timeout_cc (tc);
- tc->snd_nxt = tc->snd_una;
+ tc->snd_
una_max = tc->snd_
nxt = tc->snd_una;
tc->rto = clib_min (tc->rto << 1, TCP_RTO_MAX);
TCP_EVT_DBG (TCP_EVT_CC_EVT, tc, 1);
tc->rto = clib_min (tc->rto << 1, TCP_RTO_MAX);
TCP_EVT_DBG (TCP_EVT_CC_EVT, tc, 1);