]> asedeno.scripts.mit.edu Git - linux.git/blobdiff - net/ipv4/tcp_bbr.c
Merge branch 'for-5.5/whiskers' into for-linus
[linux.git] / net / ipv4 / tcp_bbr.c
index 95b59540eee1fbe513d1ebe345897a2cee3f3d08..32772d6ded4ed359aa4d09ba67071e88a79ebdeb 100644 (file)
@@ -388,7 +388,7 @@ static u32 bbr_bdp(struct sock *sk, u32 bw, int gain)
  * which allows 2 outstanding 2-packet sequences, to try to keep pipe
  * full even with ACK-every-other-packet delayed ACKs.
  */
-static u32 bbr_quantization_budget(struct sock *sk, u32 cwnd, int gain)
+static u32 bbr_quantization_budget(struct sock *sk, u32 cwnd)
 {
        struct bbr *bbr = inet_csk_ca(sk);
 
@@ -399,7 +399,7 @@ static u32 bbr_quantization_budget(struct sock *sk, u32 cwnd, int gain)
        cwnd = (cwnd + 1) & ~1U;
 
        /* Ensure gain cycling gets inflight above BDP even for small BDPs. */
-       if (bbr->mode == BBR_PROBE_BW && gain > BBR_UNIT)
+       if (bbr->mode == BBR_PROBE_BW && bbr->cycle_idx == 0)
                cwnd += 2;
 
        return cwnd;
@@ -411,7 +411,7 @@ static u32 bbr_inflight(struct sock *sk, u32 bw, int gain)
        u32 inflight;
 
        inflight = bbr_bdp(sk, bw, gain);
-       inflight = bbr_quantization_budget(sk, inflight, gain);
+       inflight = bbr_quantization_budget(sk, inflight);
 
        return inflight;
 }
@@ -531,7 +531,7 @@ static void bbr_set_cwnd(struct sock *sk, const struct rate_sample *rs,
         * due to aggregation (of data and/or ACKs) visible in the ACK stream.
         */
        target_cwnd += bbr_ack_aggregation_cwnd(sk);
-       target_cwnd = bbr_quantization_budget(sk, target_cwnd, gain);
+       target_cwnd = bbr_quantization_budget(sk, target_cwnd);
 
        /* If we're below target cwnd, slow start cwnd toward target cwnd. */
        if (bbr_full_bw_reached(sk))  /* only cut cwnd if we filled the pipe */