From nobody Thu Oct 12 04:21:00 2023 X-Original-To: dev-commits-src-all@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 4S5bzd19c7z4xC4M; Thu, 12 Oct 2023 04:21:01 +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 4S5bzd0TbVz4XnH; Thu, 12 Oct 2023 04:21:01 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1697084461; 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=v0pIyTlciJK/qHaR7vZEdEUfLSWhvnZiBfWQkq1JpUY=; b=nQcULb8oyTgnX1UPkw6Jf+rGYZGIBrYkoe7AZoG+ZgFx0bK655NwkkyDYKcuCRnZ7mdeev Tic2+gPZDeIQIRtA92EBMRKuyS4rhlK6nUH4vSnjqXIiPQEuh2HPcPEqys8SxxHblebivq 5jp5R9k4EIN2dNYRKEo0tBjfsskfRsQhIW6rjPEwFiCeiRe6JLdljLkfyNL1mizUT25TKR xBKjApApy80jAKPDlsz+/5zPgOQnJQq6LL2Mm5CWsTUfwcS0P6SATVd0kY0TvuqBAam7R+ TBqnviXe9cKfUiJT+bJbKLKK67trkdLilskObLYghvny5tpjr9lSxAX9GqNFGg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1697084461; a=rsa-sha256; cv=none; b=vjTr1f+WVeGpJFU9nTfAIXMAtOcGJF7dXN/FkQNNTl3CeiebkN7EiMZjcdz5NzooPeHa8z hbdhg9y2Kgn7hCpJst3dK9jjsZcHb5lZ7uxBxZzvvgbDkdWTZAP0QKHKZI2TkkCV5rdAuu SpPsUiy9dihhNkDebcAMxPuuW1uZlB8ymNo1PDqTwz3rMWHFiGbQKtFocSx8j4FHfkIVTf g9R53T7h/5/u6DNDt8hAyiqagVCNifKR4S8ubXw4EuAe0rfXt/+34DqLQgHe5CJ1dT7whe 3/lTJkaYUUQ02YBq8ZDFjNkAXYWFr9VB1jg+DqE9kr0O2xohdLVyF0suqj/XIA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1697084461; 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=v0pIyTlciJK/qHaR7vZEdEUfLSWhvnZiBfWQkq1JpUY=; b=KxwBVyM2dzTHuXl4kRf0lbwPe4cRhpY10XWgaaEk4O7mFLYX3cU2CIHzlzYG2Dn3C4wTDl OyLLV9S6hDNz6mh9fwW81YLmU7r/gBcThHw2LgZyGugimpJojG3DvzSnxD6dXOJJaMLc9M m8ZnggxyO0xUMmZ5hP9qf0RZ3KOqrK4d9rkYT8Bo+aAbDrxzwdblmB2zlJYqfB3RoqFmQf gnnnZSBfJGUcsX1DB0TPeaDlgUZiHD6ko568qyfLlfVTnpBYWoCL6HaL6wcOEwUe4KvLEZ WLjF4Z2YQK/1qUHoxvhARMRT91xp+qM1CIUTxZZ4d23i9uJAF65KsTufuI4yZg== 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 4S5bzc6c80zpVC; Thu, 12 Oct 2023 04:21:00 +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 39C4L0iU086548; Thu, 12 Oct 2023 04:21:00 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 39C4L0V1086545; Thu, 12 Oct 2023 04:21:00 GMT (envelope-from git) Date: Thu, 12 Oct 2023 04:21:00 GMT Message-Id: <202310120421.39C4L0V1086545@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Zhenlei Huang Subject: git: 0007ba082c33 - stable/13 - mbuf: Add sysctl flag CTLFLAG_TUN to loader tunables List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: dev-commits-src-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: zlei X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 0007ba082c3353f0c545e5dcf328ce30d74c5ab7 Auto-Submitted: auto-generated The branch stable/13 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=0007ba082c3353f0c545e5dcf328ce30d74c5ab7 commit 0007ba082c3353f0c545e5dcf328ce30d74c5ab7 Author: Zhenlei Huang AuthorDate: 2023-10-09 10:30:22 +0000 Commit: Zhenlei Huang CommitDate: 2023-10-12 04:19:37 +0000 mbuf: Add sysctl flag CTLFLAG_TUN to loader tunables The following sysctl variables are actually loader tunables. Add sysctl flag CTLFLAG_TUN to them so that `sysctl -T` will report them correctly. 1. kern.ipc.mb_use_ext_pgs 2. kern.ipc.nmbclusters 3. kern.ipc.nmbjumbop 4. kern.ipc.nmbjumbo9 5. kern.ipc.nmbjumbo16 6. kern.ipc.nmbufs No functional change intended. Reviewed by: kib, imp MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D42113 (cherry picked from commit 6a88498e53b24d870e066c2a94910ad23dd355eb) (cherry picked from commit b1456fd6209474410c031e5e82455588e2b656c0) --- sys/kern/kern_mbuf.c | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/sys/kern/kern_mbuf.c b/sys/kern/kern_mbuf.c index 3a5d570cb9a0..61f12ba12306 100644 --- a/sys/kern/kern_mbuf.c +++ b/sys/kern/kern_mbuf.c @@ -131,9 +131,9 @@ sysctl_mb_use_ext_pgs(SYSCTL_HANDLER_ARGS) } return (error); } -SYSCTL_PROC(_kern_ipc, OID_AUTO, mb_use_ext_pgs, CTLTYPE_INT | CTLFLAG_RW, - &mb_use_ext_pgs, 0, - sysctl_mb_use_ext_pgs, "IU", +SYSCTL_PROC(_kern_ipc, OID_AUTO, mb_use_ext_pgs, + CTLTYPE_INT | CTLFLAG_RWTUN | CTLFLAG_NOFETCH, + &mb_use_ext_pgs, 0, sysctl_mb_use_ext_pgs, "IU", "Use unmapped mbufs for sendfile(2) and TLS offload"); static quad_t maxmbufmem; /* overall real memory limit for all mbufs */ @@ -221,8 +221,8 @@ sysctl_nmbclusters(SYSCTL_HANDLER_ARGS) return (error); } SYSCTL_PROC(_kern_ipc, OID_AUTO, nmbclusters, - CTLTYPE_INT | CTLFLAG_RW | CTLFLAG_MPSAFE, &nmbclusters, 0, - sysctl_nmbclusters, "IU", + CTLTYPE_INT | CTLFLAG_RWTUN | CTLFLAG_NOFETCH | CTLFLAG_MPSAFE, + &nmbclusters, 0, sysctl_nmbclusters, "IU", "Maximum number of mbuf clusters allowed"); static int @@ -243,8 +243,8 @@ sysctl_nmbjumbop(SYSCTL_HANDLER_ARGS) return (error); } SYSCTL_PROC(_kern_ipc, OID_AUTO, nmbjumbop, - CTLTYPE_INT | CTLFLAG_RW | CTLFLAG_MPSAFE, &nmbjumbop, 0, - sysctl_nmbjumbop, "IU", + CTLTYPE_INT | CTLFLAG_RWTUN | CTLFLAG_NOFETCH | CTLFLAG_MPSAFE, + &nmbjumbop, 0, sysctl_nmbjumbop, "IU", "Maximum number of mbuf page size jumbo clusters allowed"); static int @@ -265,8 +265,8 @@ sysctl_nmbjumbo9(SYSCTL_HANDLER_ARGS) return (error); } SYSCTL_PROC(_kern_ipc, OID_AUTO, nmbjumbo9, - CTLTYPE_INT | CTLFLAG_RW | CTLFLAG_MPSAFE, &nmbjumbo9, 0, - sysctl_nmbjumbo9, "IU", + CTLTYPE_INT | CTLFLAG_RWTUN | CTLFLAG_NOFETCH | CTLFLAG_MPSAFE, + &nmbjumbo9, 0, sysctl_nmbjumbo9, "IU", "Maximum number of mbuf 9k jumbo clusters allowed"); static int @@ -287,8 +287,8 @@ sysctl_nmbjumbo16(SYSCTL_HANDLER_ARGS) return (error); } SYSCTL_PROC(_kern_ipc, OID_AUTO, nmbjumbo16, - CTLTYPE_INT | CTLFLAG_RW | CTLFLAG_MPSAFE, &nmbjumbo16, 0, - sysctl_nmbjumbo16, "IU", + CTLTYPE_INT | CTLFLAG_RWTUN | CTLFLAG_NOFETCH | CTLFLAG_MPSAFE, + &nmbjumbo16, 0, sysctl_nmbjumbo16, "IU", "Maximum number of mbuf 16k jumbo clusters allowed"); static int @@ -309,7 +309,7 @@ sysctl_nmbufs(SYSCTL_HANDLER_ARGS) return (error); } SYSCTL_PROC(_kern_ipc, OID_AUTO, nmbufs, - CTLTYPE_INT | CTLFLAG_RW | CTLFLAG_MPSAFE, + CTLTYPE_INT | CTLFLAG_RWTUN | CTLFLAG_NOFETCH | CTLFLAG_MPSAFE, &nmbufs, 0, sysctl_nmbufs, "IU", "Maximum number of mbufs allowed");