From nobody Wed Oct 11 13:07:27 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 4S5CjX1h93z4xMww; Wed, 11 Oct 2023 13:07:28 +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 4S5CjX0n5jz3Cr8; Wed, 11 Oct 2023 13:07:28 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1697029648; 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=ezN8MbbNskaDNz6OkHOwwC/SHU6NOAhMye505bFx5fE=; b=WRsHECeGW8HxJcIIvMaovETEqeajjxXTr8ghUzzYK60eUAFobSjSpup1xqDWPWMTeQFH/K w8VfFFD8WFmgv9Zxj990x2wIH5+d/iGl34ctf3GEj1MgoZzbjPXnLALYnQkntJrsuzLhmU YswpjfmY8gNy1FO8xRDdtBCs7Y1SG90LrW+QuP5RZeJTQIoU5f+YVE/7mNP9gEGmxtdBL2 HbzRGZV2YHASxcG7xhdZzGRFnhK5wiPwrGySIxgZjl2rkBItUG8xhM/+13AATpCrF9eYBS HnLcs1zCUH8Lt8IZlpqUHrH/afv+O2OAjDj+X2Mb6AGd8tp4XYqYTIOSvtZqig== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1697029648; a=rsa-sha256; cv=none; b=ogjIbg16dfy6+KOKJmx2PZuYpfMJLDOmSB9b/hc/KQhqc0rK9Yc2EJXAoWavdrFqMmwDqF 5H6ZZ+B6IGngj727xov4UmE3QjSLXkjxTxXK++95f9RF5cGHdcH88idMT8JtuXCglMnP0G aLR6sgAlzZDzlDq0jjp2Xl5QG24r/WVul9W8GJO9yaz3gf88FArMEGVXjGKSBpnPib26up rV7jCCmMocCj6inlfwXnF5WzndMwvjg0ht1PFXFZ27eiAoWcWePi6W4U2UpNovEm2a31qv olrG6AOgbweWFcXKkTdUqzRbPStsQgSMZ+nZgBPXlXyqFgsY/KMMHVBc9pfJDg== 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=1697029648; 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=ezN8MbbNskaDNz6OkHOwwC/SHU6NOAhMye505bFx5fE=; b=fmnpgCg9PGYxHlNZp563pxmB0SJCcOlG5QOP/t1TPX1EN32yR1ww3t6lZtgl5SGIPTk7mK V0RsXmRDgfQke6sPcwN3RM8Zk11a/AQKAK16/Hd3ZIQpLSCUuZyMAcCZS6/J8pNYxP3Car h9hLyxHG/gFkHCzh2GdzJ1i5xndLj3qGNks6pBTsbgas+upsLuPRh21dIA1qFZlaKtyhhe h1quyDXCHJz2sbi3g8N6h8rkyRdXWKXxccnu+9cX5c7nTs9zvJvZAP/EjyRhKJ9cxFkNoV jRKKyjE9ZLQDC6aooePrRNZWR+nDd/0cyfCOq9QVzQE+E9Rr801+wJD6NUtUOQ== 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 4S5CjW6xbCz7BR; Wed, 11 Oct 2023 13:07:27 +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 39BD7RCP056269; Wed, 11 Oct 2023 13:07:27 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 39BD7R3G056266; Wed, 11 Oct 2023 13:07:27 GMT (envelope-from git) Date: Wed, 11 Oct 2023 13:07:27 GMT Message-Id: <202310111307.39BD7R3G056266@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Mateusz Guzik Subject: git: 281a9715b582 - main - vfs: add max_vnlru_free to the vfs.vnode.vnlru tree 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: mjg X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 281a9715b582861fe4097c2f27eb27b208d752b1 Auto-Submitted: auto-generated The branch main has been updated by mjg: URL: https://cgit.FreeBSD.org/src/commit/?id=281a9715b582861fe4097c2f27eb27b208d752b1 commit 281a9715b582861fe4097c2f27eb27b208d752b1 Author: Mateusz Guzik AuthorDate: 2023-10-11 13:05:43 +0000 Commit: Mateusz Guzik CommitDate: 2023-10-11 13:07:13 +0000 vfs: add max_vnlru_free to the vfs.vnode.vnlru tree While here rename the var internally. --- sys/kern/vfs_subr.c | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/sys/kern/vfs_subr.c b/sys/kern/vfs_subr.c index 99933a6b9c88..d21ccb4251cd 100644 --- a/sys/kern/vfs_subr.c +++ b/sys/kern/vfs_subr.c @@ -1306,9 +1306,11 @@ next_iter: return (done); } -static int max_vnlru_free = 10000; /* limit on vnode free requests per call */ -SYSCTL_INT(_debug, OID_AUTO, max_vnlru_free, CTLFLAG_RW, &max_vnlru_free, - 0, +static int max_free_per_call = 10000; +SYSCTL_INT(_debug, OID_AUTO, max_vnlru_free, CTLFLAG_RW, &max_free_per_call, 0, + "limit on vnode free requests per call to the vnlru_free routine (legacy)"); +SYSCTL_INT(_vfs_vnode_vnlru, OID_AUTO, max_free_per_call, CTLFLAG_RW, + &max_free_per_call, 0, "limit on vnode free requests per call to the vnlru_free routine"); /* @@ -1323,8 +1325,8 @@ vnlru_free_impl(int count, struct vfsops *mnt_op, struct vnode *mvp) bool retried; mtx_assert(&vnode_list_mtx, MA_OWNED); - if (count > max_vnlru_free) - count = max_vnlru_free; + if (count > max_free_per_call) + count = max_free_per_call; if (count == 0) { mtx_unlock(&vnode_list_mtx); return (0);