Received: by 2002:a25:e7d8:0:0:0:0:0 with SMTP id e207csp3030628ybh; Mon, 16 Mar 2020 14:27:21 -0700 (PDT) X-Google-Smtp-Source: ADFU+vvAg5MsOqqydg8Nwrd7llzwki5yCzKq94bS6gaM1vfiTj2tARCpeWhrfROJvuiY0YfIgnq2 X-Received: by 2002:a9d:6f07:: with SMTP id n7mr978728otq.247.1584394041483; Mon, 16 Mar 2020 14:27:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1584394041; cv=none; d=google.com; s=arc-20160816; b=hjAX6uMGOuheqHn0sqjcmhUm2STMGRk5dJ1tkSSdBIMCY/Y1j0LqO8jog5KwXluYoR 5Kqe7zxYZT5a6UofyaPau7V9OHJD/qqoaUdAFoW+APf89FaYXZdQGV0TmVZ+eiqzfRtR 61ixIUCZ22rKeNYmabGLqPfIv3WIszieT4AsMWPJFWNlLo1OxeQSScIZNhnI3mxIbgVU O2oemWLLdUcOTdZMeWs5OolwUU+RkglAbujpXv7SIP37nvOQIwFrxqhKZQWFlRmUh5jY BLGXw1cFBW6AUq8562th1e4LqOwyHAU3rx75bBTALo9UeUJDUbZnEz/1NjGBmor2I4Ly QAUQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=v7jm6R1lI66fN9dOATmAhH/neJJRs+NMkuLfeIMHpr8=; b=SMzSO+HFUCAv2fBPUm1PzTY90TKr97WIqd7fLW8RDKSQY6JBw0MivJbUVvQkk72xyj pQrmqDG3O8JgCU3WNLj668DAnHsEeIyhN5u0IphBcemPBTuuHIQDNR/BsYMxNYHF9CJM VG8alnucONejWfTkYkS5P9SEAZEgoSpFtruoeshisyWyRwpfyOUMgWWoJ2LoPF8/Si/s O50RMfawRHFJrvtU03n/guSOO1YjabPsabK+G9AgLap/mS9R+wJfhZ+pbEaThchZXOdw 23nfdwJd+N/pLaGyYV3v8EgnfqBY65B1f71BrqDZlZdvDKCmm9rEydQi37m/3vFNmoCK rT9w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=fw+Fzk5N; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id e11si610198oib.152.2020.03.16.14.27.09; Mon, 16 Mar 2020 14:27:21 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=fw+Fzk5N; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732679AbgCPVZ7 (ORCPT + 99 others); Mon, 16 Mar 2020 17:25:59 -0400 Received: from mail-oi1-f196.google.com ([209.85.167.196]:38692 "EHLO mail-oi1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1732641AbgCPVZ7 (ORCPT ); Mon, 16 Mar 2020 17:25:59 -0400 Received: by mail-oi1-f196.google.com with SMTP id k21so19491982oij.5 for ; Mon, 16 Mar 2020 14:25:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=v7jm6R1lI66fN9dOATmAhH/neJJRs+NMkuLfeIMHpr8=; b=fw+Fzk5Nm5NC9Jjvn8y+I4rt14Z5Txz55IHQeV31ArJE88uELShhqpnkObRE5QZtmD jYMj0aYW4UFoNXmQYdsS7keXHF7J8MPwMX0fqG/DLhwfR4JW1s2tbnlFC2Ox7c0faXxJ b4K3YRyFMGS85VJnlMqBlqbcjmhoGhEjqw/5iwJkh2GA5Kli9USgQhTUXHtX/PDrI/kA Ro1G92+6c6x/dfMwER6p7Vg/PWNh201KOudDxPtz46mvigy08VngVUd4a9UkkBaXkNmM uS2lXIgqwdnUp2rhhr9ii9uFKVJFxThazdVykMUW+Cpqux+603zJr9aaHk0o6jfMw2Dv pzLw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=v7jm6R1lI66fN9dOATmAhH/neJJRs+NMkuLfeIMHpr8=; b=uYoNpndQPa8H39NBHMHYGUcNnPVsYRLQD82FN7K7fU3sZaT4IpitWCtKBAS8DEAZ2r NwNCwnrA34mAEwpw4LdBJY3WPsDuldbhL19+q+Ge/6s9PthvR5+Dh0vsjV2+tLeoeFQe Z2nzPg96xRjmtFOuwR8oOTpDk7TEeH1bZ03OfmFLWiEvXqira2qubp0D222pI/Vzs95d h1EndMZheI38P34sli7htDgVU3EVfunT4/PJjHFH/Vc6jN+Jx9xiYFGaNoETVoFDxROs M4Mzyi50AaDMgR2BvrfbT2dSX78z/Ugg4aFzkG1B/9utA3xR8z25z8Iz6oKsQeNDl+Pa Wt7A== X-Gm-Message-State: ANhLgQ2bQ49g+8dpTEgteugj9qzKa7Oo4V+LwkPabwuLHG877BPvIX8R L9AHk8PiLmJJMP/5CK01IAWSgWvtoWP13RryjErVtw== X-Received: by 2002:aca:aa12:: with SMTP id t18mr1157072oie.95.1584393957751; Mon, 16 Mar 2020 14:25:57 -0700 (PDT) MIME-Version: 1.0 References: <1584340511-9870-1-git-send-email-yangpc@wangsu.com> <1584340511-9870-3-git-send-email-yangpc@wangsu.com> In-Reply-To: <1584340511-9870-3-git-send-email-yangpc@wangsu.com> From: Neal Cardwell Date: Mon, 16 Mar 2020 17:25:41 -0400 Message-ID: Subject: Re: [PATCH RESEND net-next v2 2/5] tcp: fix stretch ACK bugs in Scalable To: Pengcheng Yang Cc: Eric Dumazet , David Miller , Netdev , LKML Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Mar 16, 2020 at 2:37 AM Pengcheng Yang wrote: > > Change Scalable to properly handle stretch ACKs in additive > increase mode by passing in the count of ACKed packets to > tcp_cong_avoid_ai(). > > In addition, because we are now precisely accounting for > stretch ACKs, including delayed ACKs, we can now change > TCP_SCALABLE_AI_CNT to 100. > > Signed-off-by: Pengcheng Yang > --- > net/ipv4/tcp_scalable.c | 17 +++++++++-------- > 1 file changed, 9 insertions(+), 8 deletions(-) > > diff --git a/net/ipv4/tcp_scalable.c b/net/ipv4/tcp_scalable.c > index 471571e..6cebf41 100644 > --- a/net/ipv4/tcp_scalable.c > +++ b/net/ipv4/tcp_scalable.c > @@ -10,10 +10,9 @@ > #include > > /* These factors derived from the recommended values in the aer: > - * .01 and and 7/8. We use 50 instead of 100 to account for > - * delayed ack. > + * .01 and and 7/8. > */ > -#define TCP_SCALABLE_AI_CNT 50U > +#define TCP_SCALABLE_AI_CNT 100U > #define TCP_SCALABLE_MD_SCALE 3 > > static void tcp_scalable_cong_avoid(struct sock *sk, u32 ack, u32 acked) > @@ -23,11 +22,13 @@ static void tcp_scalable_cong_avoid(struct sock *sk, u32 ack, u32 acked) > if (!tcp_is_cwnd_limited(sk)) > return; > > - if (tcp_in_slow_start(tp)) > - tcp_slow_start(tp, acked); > - else > - tcp_cong_avoid_ai(tp, min(tp->snd_cwnd, TCP_SCALABLE_AI_CNT), > - 1); > + if (tcp_in_slow_start(tp)) { > + acked = tcp_slow_start(tp, acked); > + if (!acked) > + return; > + } > + tcp_cong_avoid_ai(tp, min(tp->snd_cwnd, TCP_SCALABLE_AI_CNT), > + acked); > } > > static u32 tcp_scalable_ssthresh(struct sock *sk) > -- Acked-by: Neal Cardwell thanks, neal