diff --git a/draft-ietf-quic-recovery.md b/draft-ietf-quic-recovery.md index 210eaf848a..3957a55f75 100644 --- a/draft-ietf-quic-recovery.md +++ b/draft-ietf-quic-recovery.md @@ -719,10 +719,12 @@ as follows: For example, assume: +~~~ smoothed_rtt = 1 rttvar = 0 max_ack_delay = 0 kPersistentCongestionThreshold = 3 +~~~ If an ack-eliciting packet is sent at time = 0, the following scenario would illustrate persistent congestion: @@ -1407,15 +1409,23 @@ Invoked when an ACK frame with an ECN section is received from the peer. Invoked from DetectLostPackets when packets are deemed lost. ~~~ - InPersistentCongestion(largest_lost_packet): + InPersistentCongestion(lost_packets): pto = smoothed_rtt + max(4 * rttvar, kGranularity) + max_ack_delay congestion_period = pto * kPersistentCongestionThreshold + + earliest_lost_packet = lost_packets.first() + largest_lost_packet = lost_packets.last() + // Determine if all packets in the time period before the // newest lost packet, including the edges, are marked // lost - return AreAllPacketsLost(largest_lost_packet, - congestion_period) + all_packets_lost = + lost_packets.length() == (lost_packets.last().packet_number - + lost_packets.first().packet_number + 1) + + return all_packets_lost && congestion_period > + largest_lost_packet.time_sent - earliest_lost_packet.time_sent OnPacketsLost(lost_packets): // Remove lost packets from bytes_in_flight. @@ -1425,7 +1435,7 @@ Invoked from DetectLostPackets when packets are deemed lost. CongestionEvent(largest_lost_packet.time_sent) // Collapse congestion window if persistent congestion - if (InPersistentCongestion(largest_lost_packet)): + if (InPersistentCongestion(lost_packets)): congestion_window = kMinimumWindow ~~~