Skip to content

net/tcp_timer: fix tcp RTO abnormally large after retransmission occurs #15118

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Dec 10, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion net/tcp/tcp_timer.c
Original file line number Diff line number Diff line change
Expand Up @@ -599,7 +599,8 @@ void tcp_timer(FAR struct net_driver_s *dev, FAR struct tcp_conn_s *conn)

/* Exponential backoff. */

conn->timer = TCP_RTO << (conn->nrtx > 4 ? 4: conn->nrtx);
conn->rto = TCP_RTO << (conn->nrtx > 4 ? 4: conn->nrtx);
tcp_update_retrantimer(conn, conn->rto);
conn->nrtx++;

/* Ok, so we need to retransmit. We do this differently
Expand Down
Loading