Skip to content
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

Replace alarm with timer #1559

Merged
merged 6 commits into from Jul 15, 2018
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
25 changes: 12 additions & 13 deletions draft-ietf-quic-recovery.md
Expand Up @@ -784,34 +784,33 @@ Pseudocode for SetLossDetectionTimer follows:
if (handshake packets are outstanding):
// Handshake retransmission timer.
if (smoothed_rtt == 0):
timer_duration = 2 * kInitialRtt
timeout = 2 * kInitialRtt
else:
timer_duration = 2 * smoothed_rtt
timer_duration = max(timer_duration + max_ack_delay,
kMinTLPTimeout)
timer_duration = timer_duration * (2 ^ handshake_count)
timeout = 2 * smoothed_rtt
timeout = max(timeout + max_ack_delay, kMinTLPTimeout)
timeout = timeout * (2 ^ handshake_count)
loss_detection_timer.set(
time_of_last_sent_handshake_packet + timer_duration)
time_of_last_sent_handshake_packet + timeout)
return;
else if (loss_time != 0):
// Early retransmit timer or time loss detection.
timer_duration = loss_time -
timeout = loss_time -
time_of_last_sent_retransmittable_packet
else:
// RTO or TLP timer
// Calculate RTO duration
timer_duration =
timeout =
smoothed_rtt + 4 * rttvar + max_ack_delay
timer_duration = max(timer_duration, kMinRTOTimeout)
timer_duration = timer_duration * (2 ^ rto_count)
timeout = max(timeout, kMinRTOTimeout)
timeout = timeout * (2 ^ rto_count)
if (tlp_count < kMaxTLPs):
// Tail Loss Probe
tlp_timer_duration = max(1.5 * smoothed_rtt
tlp_timeout = max(1.5 * smoothed_rtt
+ max_ack_delay, kMinTLPTimeout)
timer_duration = min(tlp_timer_duration, timer_duration)
timeout = min(tlp_timeout, timeout)

loss_detection_timer.set(
time_of_last_sent_retransmittable_packet + timer_duration)
time_of_last_sent_retransmittable_packet + timeout)
~~~

### On Timeout
Expand Down