Skip to content

Commit

Permalink
issue: 4043235 TCP_USER_TIMER wrong RTO behavior
Browse files Browse the repository at this point in the history
Fix inconsistency in TCP timer resolution settings leading to incorrect
TCP_USER_TIMEOUT behavior.

This inconsistency caused the slow_tmr_interval
(which is derived from the timer resolution) to be incorrect,
leading to miscalculations of user_timeout_ticks.

As a result, the TCP_USER_TIMEOUT mechanism was not functioning
as expected, causing additional retransmissions beyond
the configured timeout.

By updating the set_tmr_resolution to use
safe_mce_sys().tcp_timer_resolution_msec * 2, both the timer resolution
and the timer event interval are now consistent.

Signed-off-by: Tomer Cabouly <tcabouly@nvidia.com>
  • Loading branch information
tomerdbz committed Jan 14, 2025
1 parent ea2d6e2 commit 181718c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/core/proto/xlio_lwip.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ xlio_lwip::xlio_lwip()
register_tcp_state_observer(sockinfo_tcp::tcp_state_observer);
register_ip_route_mtu(sockinfo_tcp::get_route_mtu);
register_sys_now(sys_now);
set_tmr_resolution(safe_mce_sys().tcp_timer_resolution_msec);
set_tmr_resolution(safe_mce_sys().tcp_timer_resolution_msec * 2);
// tcp_ticks increases in the rate of tcp slow_timer
void *node = g_p_event_handler_manager->register_timer_event(
safe_mce_sys().tcp_timer_resolution_msec * 2, this, PERIODIC_TIMER, nullptr);
Expand Down

0 comments on commit 181718c

Please sign in to comment.