tcp_session_push_header (transport_connection_t * tconn, vlib_buffer_t * b)
{
tcp_connection_t *tc = (tcp_connection_t *) tconn;
tcp_session_push_header (transport_connection_t * tconn, vlib_buffer_t * b)
{
tcp_connection_t *tc = (tcp_connection_t *) tconn;
tcp_push_hdr_i (tc, b, tc->snd_nxt, /* compute opts */ 0, /* burst */ 1,
/* update_snd_nxt */ 1);
tcp_push_hdr_i (tc, b, tc->snd_nxt, /* compute opts */ 0, /* burst */ 1,
/* update_snd_nxt */ 1);
tc->snd_una_max = seq_max (tc->snd_nxt, tc->snd_una_max);
tcp_validate_txf_size (tc, tc->snd_una_max - tc->snd_una);
/* If not tracking an ACK, start tracking */
tc->snd_una_max = seq_max (tc->snd_nxt, tc->snd_una_max);
tcp_validate_txf_size (tc, tc->snd_una_max - tc->snd_una);
/* If not tracking an ACK, start tracking */
- tc->snd_rxt_bytes += n_bytes;
+ {
+ tc->snd_rxt_bytes += n_bytes;
+ if (tc->flags & TCP_CONN_RATE_SAMPLE)
+ tcp_bt_track_rxt (tc, start, start + n_bytes);
+ }
done:
TCP_EVT_DBG (TCP_EVT_CC_RTX, tc, offset, n_bytes);
done:
TCP_EVT_DBG (TCP_EVT_CC_RTX, tc, offset, n_bytes);
/* If we've sent beyond snd_congestion, update it */
tc->snd_congestion = seq_max (tc->snd_nxt, tc->snd_congestion);
/* If we've sent beyond snd_congestion, update it */
tc->snd_congestion = seq_max (tc->snd_nxt, tc->snd_congestion);