tcp_set_time_now (wrk);
tw_timer_expire_timers_16t_2w_512sl (&wrk->timer_wheel, now);
tcp_do_fastretransmits (wrk);
+ tcp_send_acks (wrk);
tcp_flush_frames_to_output (wrk);
}
tcp_connection_tx_pacer_update (tcp_connection_t * tc)
{
f64 srtt;
+ u64 rate;
if (!transport_connection_is_tx_paced (&tc->connection))
return;
srtt = clib_min ((f64) tc->srtt * TCP_TICK, tc->mrtt_us);
- transport_connection_tx_pacer_update (&tc->connection,
- ((f64) tc->cwnd) / srtt);
+ /* TODO should constrain to interface's max throughput but
+ * we don't have link speeds for sw ifs ..*/
+ rate = tc->cwnd / srtt;
+ transport_connection_tx_pacer_update (&tc->connection, rate);
}
void
vec_validate (tm->wrk_ctx[thread].ongoing_fast_rxt, 255);
vec_validate (tm->wrk_ctx[thread].postponed_fast_rxt, 255);
vec_validate (tm->wrk_ctx[thread].pending_deq_acked, 255);
+ vec_validate (tm->wrk_ctx[thread].pending_acks, 255);
vec_reset_length (tm->wrk_ctx[thread].pending_fast_rxt);
vec_reset_length (tm->wrk_ctx[thread].ongoing_fast_rxt);
vec_reset_length (tm->wrk_ctx[thread].postponed_fast_rxt);
vec_reset_length (tm->wrk_ctx[thread].pending_deq_acked);
+ vec_reset_length (tm->wrk_ctx[thread].pending_acks);
tm->wrk_ctx[thread].vm = vlib_mains[thread];
/*
FIB_PROTOCOL_IP6, tcp6_output_node.index);
tcp_api_reference ();
+ tm->tx_pacing = 1;
return 0;
}
else if (unformat (input, "max-rx-fifo %U", unformat_memory_size,
&tm->max_rx_fifo))
;
- else if (unformat (input, "tx-pacing"))
- tm->tx_pacing = 1;
+ else if (unformat (input, "no-tx-pacing"))
+ tm->tx_pacing = 0;
else
return clib_error_return (0, "unknown input `%U'",
format_unformat_error, input);