From nobody Thu Feb 08 17:39:19 2024 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4TW43q3NvCz5B5YX; Thu, 8 Feb 2024 17:39:19 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4TW43q2t2qz4c98; Thu, 8 Feb 2024 17:39:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1707413959; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=VYqHY6oI/XMLlIu1/A8H+anTMujirqB0HGLR1vN85qg=; b=fUC3SJMhuj2kzL66KowNvoHGOfgVn6xgnSTS6ggKzSjjDh6XVImrAO8bpwQc6gyKFO8g26 cv7XOJwTyG2fjojHosVozoNcassCn55dFIkoiu40yUtHqYqCtcjkr4hdIVyfKIfUxcqr6O gKoGs3c3sysmR5CguceVBUDfkndJzAYFxOkk+/Ue7NodWNS3IK7JHJuO6oAmfLnIKcFjU/ +I/6UXATINUhyMietYJPmOmTj9LQoFaxq23eSP9Lv609Umi7Rn1Jxzvcw5EtjlCPPNmPig GTFgNC2yG/rcEfSPJOTlj2H1vjwZRAZI06KSauTJ7EMPbepZWsdJJtYghyw9Cw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1707413959; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=VYqHY6oI/XMLlIu1/A8H+anTMujirqB0HGLR1vN85qg=; b=XcDmFfo/unvmnmeMCMsrF+LSEWrdlN5HRoh3UX5WWdqPg07HA41arNzZJZWpvGssQWTwJk wOa0Zs3zRSulXtuED4KOelqEuiyuAc6JYzFL3ksbd7zSyuiHG0/mWpnQDYdzn3UfGzEtQx ZbwLk5GZLZtViGys68wHpn7YfH1rPPXNwntS87HyY0WaE+uNhw3/aSEsPqKcODi2beSChU 7n++TNHwlFXEczuoIw0/HR9M4cwgOyAmCtdeij7zI/1vOuBJXS4QI3LVMJ8nIF7XVmiMn8 Y+SZzO0KBDot0LBh/26mErpfG/+gfpEDHeyQ2noY15npWs1rbXSJ12l/BkZMFQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1707413959; a=rsa-sha256; cv=none; b=POrWMR3iYnetgoGtlMUudRLxMc+GwCvg7MluuBJBp3f142WJAOVuUlTD7c3NFtJ2GkCXzV P00QR8lcsTH+IGOn0i8G7tCMWrpmD0KBcy4B00kq8IZ4t3B5+zD3qVUDBt5Rxe0FUCBhPz 8j8nVlUc+iaK+a/I6X+7M3eA0jdeNPyxYR8mgt23ISSC0w2HzGvBKdHuFtqMh0DFQEghMo AO85D9Dcgjwwxw/Av6OjEwO5vmSF+HStZFsn+4APd5irEtxvshNCYsrbLmkrpNMEkvvrV7 aV0w8rdYWbG08COfELq83zCKXwVhfLKfvOC/1i+PV0jURGZrk7qXkmAwDC1Dpw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4TW43q1wz6zyrV; Thu, 8 Feb 2024 17:39:19 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 418HdJl8024151; Thu, 8 Feb 2024 17:39:19 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 418HdJsK024148; Thu, 8 Feb 2024 17:39:19 GMT (envelope-from git) Date: Thu, 8 Feb 2024 17:39:19 GMT Message-Id: <202402081739.418HdJsK024148@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Richard Scheffenegger Subject: git: 1adab814e813 - main - tcp: use tcp_fixed_maxseg instead of tcp_maxseg in cc modules List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-main@freebsd.org X-BeenThere: dev-commits-src-main@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: rscheff X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 1adab814e8136ec26e8efbdb40e671d943d7fbf0 Auto-Submitted: auto-generated The branch main has been updated by rscheff: URL: https://cgit.FreeBSD.org/src/commit/?id=1adab814e8136ec26e8efbdb40e671d943d7fbf0 commit 1adab814e8136ec26e8efbdb40e671d943d7fbf0 Author: Richard Scheffenegger AuthorDate: 2024-02-08 16:56:29 +0000 Commit: Richard Scheffenegger CommitDate: 2024-02-08 17:36:59 +0000 tcp: use tcp_fixed_maxseg instead of tcp_maxseg in cc modules tcp_fixed_maxseg() is the streamlined calculation of typical tcp options and more suitable for heavy use in the congestion control modules on every received packet. No external functional change. Reviewed By: tuexen, #transport Sponsored by: NetApp, Inc. Differential Revision: https://reviews.freebsd.org/D43779 --- sys/netinet/cc/cc.c | 2 +- sys/netinet/cc/cc_cubic.c | 2 +- sys/netinet/cc/cc_dctcp.c | 2 +- sys/netinet/cc/cc_htcp.c | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/sys/netinet/cc/cc.c b/sys/netinet/cc/cc.c index ea8cb904c7aa..ff25b8368cc4 100644 --- a/sys/netinet/cc/cc.c +++ b/sys/netinet/cc/cc.c @@ -440,7 +440,7 @@ newreno_cc_after_idle(struct cc_var *ccv) * maximum of the former ssthresh or 3/4 of the old cwnd, to * not exit slow-start prematurely. */ - rw = tcp_compute_initwnd(tcp_maxseg(ccv->ccvc.tcp)); + rw = tcp_compute_initwnd(tcp_fixed_maxseg(ccv->ccvc.tcp)); CCV(ccv, snd_ssthresh) = max(CCV(ccv, snd_ssthresh), CCV(ccv, snd_cwnd)-(CCV(ccv, snd_cwnd)>>2)); diff --git a/sys/netinet/cc/cc_cubic.c b/sys/netinet/cc/cc_cubic.c index 7a357e39182e..3f7ba630db5d 100644 --- a/sys/netinet/cc/cc_cubic.c +++ b/sys/netinet/cc/cc_cubic.c @@ -423,7 +423,7 @@ cubic_cong_signal(struct cc_var *ccv, uint32_t type) u_int mss; cubic_data = ccv->cc_data; - mss = tcp_maxseg(ccv->ccvc.tcp); + mss = tcp_fixed_maxseg(ccv->ccvc.tcp); switch (type) { case CC_NDUPACK: diff --git a/sys/netinet/cc/cc_dctcp.c b/sys/netinet/cc/cc_dctcp.c index 8084439aafaa..efb8913ec36c 100644 --- a/sys/netinet/cc/cc_dctcp.c +++ b/sys/netinet/cc/cc_dctcp.c @@ -245,7 +245,7 @@ dctcp_cong_signal(struct cc_var *ccv, uint32_t type) if (CCV(ccv, t_flags2) & TF2_ECN_PERMIT) { dctcp_data = ccv->cc_data; cwin = CCV(ccv, snd_cwnd); - mss = tcp_maxseg(ccv->ccvc.tcp); + mss = tcp_fixed_maxseg(ccv->ccvc.tcp); switch (type) { case CC_NDUPACK: diff --git a/sys/netinet/cc/cc_htcp.c b/sys/netinet/cc/cc_htcp.c index d31720d0099f..c9304fcfc8e5 100644 --- a/sys/netinet/cc/cc_htcp.c +++ b/sys/netinet/cc/cc_htcp.c @@ -284,7 +284,7 @@ htcp_cong_signal(struct cc_var *ccv, uint32_t type) u_int mss; htcp_data = ccv->cc_data; - mss = tcp_maxseg(ccv->ccvc.tcp); + mss = tcp_fixed_maxseg(ccv->ccvc.tcp); switch (type) { case CC_NDUPACK: