From nobody Sun Nov 06 11:39:37 2022 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 4N4spd457Jz4gySQ; Sun, 6 Nov 2022 11:39:37 +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 4N4spd32j7z43Jt; Sun, 6 Nov 2022 11:39:37 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1667734777; 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=w9Zz67j9xA36QLUZWFJSvm41PP5Au4pPd2upopAe08g=; b=Akumkdc8Qh1LPpR9tAwZ9amkvyoxlZKEjs03UeNcn5WE/2b/Qb4XHICtd2LAH31gx9kFhj PtxA0LLS777jcGjE1xbomcLd5SMOad8Hdri4Jp4GBmpLRwWP4p6q/6y2Wr6/eUx8qy2ZEw iPa2MGWEsEFyYAeKkV4YkEPKhkmoqMA/qWAvcxkpjv1i4VmkzG0hNj7Wgyg/oiYseMMmFm /N6aQ4xmd6sg642mFWpg9wQhPkD5WBai0wbDfQ+BGMqfnJilNjVOSI6qB2xSuI/lVMZUOC YRq+PgGWVYS5kmSFSbd9OvlKGVXHFoBFnhHd5QhohEMAbbMgtgNj1pD9l/mPjg== 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 4N4spd20xTzKfW; Sun, 6 Nov 2022 11:39:37 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 2A6BdbG7043015; Sun, 6 Nov 2022 11:39:37 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 2A6BdbNw043014; Sun, 6 Nov 2022 11:39:37 GMT (envelope-from git) Date: Sun, 6 Nov 2022 11:39:37 GMT Message-Id: <202211061139.2A6BdbNw043014@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: 004bb636ca65 - main - tcp: Move sysctl OIDs related to ECN to tcp_ecn.c 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: 004bb636ca65f3239da284c20abb7f9d1d953dee Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1667734777; 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=w9Zz67j9xA36QLUZWFJSvm41PP5Au4pPd2upopAe08g=; b=UkvlHvV/R8Dn5FBEm/uQBk7ObddFjOFyQnWowkn3L+ep/KVTJy+JI45fyv9+pEN+S6kIYp QlQuzVu7K8YjkG25rbjwQk7H5+aKjJXGsPquFmIn7Fa6g2s0QnY83anIu8aPkFI30aIj19 9xDdE7RNAmjbOlt+5DJhcUknHz7M0kFiL6dJAupI2FwYp4xtIOuu3ikSgbZxH2jJ4zTzwi 8TZ+IRG0YRhmiXdlNhqkdv9SQEesBUD5prKAQ+m6dSFWO+t93qW9JskByS2WvDvvKLrJzu 9/fAUalLWk36PsEU/A8S2Q7uwfjcgJm2W8M5v4hY6BFAyoKLZsGNeB5vzZg0dA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1667734777; a=rsa-sha256; cv=none; b=TEAwL4FEGkFqTopsB8UwSN7zaiBj98CzhOofFnuYrB3iY818W370O6RjDdUOkZDJu7K/YE dyfsfyFOlgMAPSuiHWyF8lNocgJIMdM2LSuFl+noOjARhaLw/RSenXCdy5cwrMAt/+i7j9 sQjVpjcjGKeGknX0lUqA7/uX2avdaBrj18xjk9CgsIhvxLUZ+xThRP3VIqjFwPLI0czYbR WDt9qauZXygLwn7YsU5jImC+CxBuWdGLrJaJGo9J7Tvw2ZbjkTysWjRVIx8OYGGCBV907J l8omgQDUdZxivMLzbqgYIFGA1crIeg1pvGVztI1UZLnlX5Cs/UuPEYADDdcV5Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by rscheff: URL: https://cgit.FreeBSD.org/src/commit/?id=004bb636ca65f3239da284c20abb7f9d1d953dee commit 004bb636ca65f3239da284c20abb7f9d1d953dee Author: Richard Scheffenegger AuthorDate: 2022-11-06 11:36:55 +0000 Commit: Richard Scheffenegger CommitDate: 2022-11-06 11:38:42 +0000 tcp: Move sysctl OIDs related to ECN to tcp_ecn.c Keep all ECN related code in (mostly) one place. No functional change. Event: IETF 115 Hackathon Reviewed By: tuexen, #transport Sponsored by: NetApp, Inc. Differential Revision: https://reviews.freebsd.org/D37285 --- sys/netinet/tcp_ecn.c | 13 +++++++++++++ sys/netinet/tcp_input.c | 14 -------------- 2 files changed, 13 insertions(+), 14 deletions(-) diff --git a/sys/netinet/tcp_ecn.c b/sys/netinet/tcp_ecn.c index 40791172e55f..3cbc1c53dad7 100644 --- a/sys/netinet/tcp_ecn.c +++ b/sys/netinet/tcp_ecn.c @@ -101,6 +101,19 @@ __FBSDID("$FreeBSD$"); #include #include +static SYSCTL_NODE(_net_inet_tcp, OID_AUTO, ecn, + CTLFLAG_RW | CTLFLAG_MPSAFE, 0, + "TCP ECN"); + +VNET_DEFINE(int, tcp_do_ecn) = 2; +SYSCTL_INT(_net_inet_tcp_ecn, OID_AUTO, enable, + CTLFLAG_VNET | CTLFLAG_RW, &VNET_NAME(tcp_do_ecn), 0, + "TCP ECN support"); + +VNET_DEFINE(int, tcp_ecn_maxretries) = 1; +SYSCTL_INT(_net_inet_tcp_ecn, OID_AUTO, maxretries, + CTLFLAG_VNET | CTLFLAG_RW, &VNET_NAME(tcp_ecn_maxretries), 0, + "Max retries before giving up on ECN"); /* * Process incoming SYN,ACK packet diff --git a/sys/netinet/tcp_input.c b/sys/netinet/tcp_input.c index a1787a0f93db..370b947767ff 100644 --- a/sys/netinet/tcp_input.c +++ b/sys/netinet/tcp_input.c @@ -204,20 +204,6 @@ SYSCTL_INT(_net_inet_tcp, OID_AUTO, abc_l_var, CTLFLAG_VNET | CTLFLAG_RW, &VNET_NAME(tcp_abc_l_var), 2, "Cap the max cwnd increment during slow-start to this number of segments"); -static SYSCTL_NODE(_net_inet_tcp, OID_AUTO, ecn, - CTLFLAG_RW | CTLFLAG_MPSAFE, 0, - "TCP ECN"); - -VNET_DEFINE(int, tcp_do_ecn) = 2; -SYSCTL_INT(_net_inet_tcp_ecn, OID_AUTO, enable, CTLFLAG_VNET | CTLFLAG_RW, - &VNET_NAME(tcp_do_ecn), 0, - "TCP ECN support"); - -VNET_DEFINE(int, tcp_ecn_maxretries) = 1; -SYSCTL_INT(_net_inet_tcp_ecn, OID_AUTO, maxretries, CTLFLAG_VNET | CTLFLAG_RW, - &VNET_NAME(tcp_ecn_maxretries), 0, - "Max retries before giving up on ECN"); - VNET_DEFINE(int, tcp_insecure_syn) = 0; SYSCTL_INT(_net_inet_tcp, OID_AUTO, insecure_syn, CTLFLAG_VNET | CTLFLAG_RW, &VNET_NAME(tcp_insecure_syn), 0,