From owner-dev-commits-src-all@freebsd.org Mon Aug 23 13:51:52 2021 Return-Path: Delivered-To: dev-commits-src-all@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 0FE7E66BCC0; Mon, 23 Aug 2021 13:51:52 +0000 (UTC) (envelope-from cy.schubert@cschubert.com) Received: from omta002.cacentral1.a.cloudfilter.net (omta002.cacentral1.a.cloudfilter.net [3.97.99.33]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "Client", Issuer "CA" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4GtYZH5zwQz4RRY; Mon, 23 Aug 2021 13:51:51 +0000 (UTC) (envelope-from cy.schubert@cschubert.com) Received: from shw-obgw-4003a.ext.cloudfilter.net ([10.228.9.183]) by cmsmtp with ESMTP id I8fbm5uL24bInIAMbmHVlt; Mon, 23 Aug 2021 13:51:45 +0000 Received: from spqr.komquats.com ([70.66.148.124]) by cmsmtp with ESMTPA id IAMamjck1qeviIAMamF6GY; Mon, 23 Aug 2021 13:51:45 +0000 X-Authority-Analysis: v=2.4 cv=B4F8bMhM c=1 sm=1 tr=0 ts=6123a7f1 a=Cwc3rblV8FOMdVN/wOAqyQ==:117 a=Cwc3rblV8FOMdVN/wOAqyQ==:17 a=kj9zAlcOel0A:10 a=MhDmnRu9jo8A:10 a=6I5d2MoRAAAA:8 a=YxBL1-UpAAAA:8 a=EkcXrb_YAAAA:8 a=p8d-jTAGzcGgB6t1mYAA:9 a=CjuIK1q_8ugA:10 a=IjZwj45LgO3ly-622nXo:22 a=Ia-lj3WSrqcvXOmTRaiG:22 a=LK5xJRSDVpKd5WXXoEvA:22 Received: from slippy.cwsent.com (slippy [10.1.1.91]) by spqr.komquats.com (Postfix) with ESMTPS id 4CF0930C; Mon, 23 Aug 2021 06:51:43 -0700 (PDT) Received: from slippy (localhost [127.0.0.1]) by slippy.cwsent.com (8.16.1/8.16.1) with ESMTP id 17NDphg3006806; Mon, 23 Aug 2021 06:51:43 -0700 (PDT) (envelope-from Cy.Schubert@cschubert.com) Message-Id: <202108231351.17NDphg3006806@slippy.cwsent.com> X-Mailer: exmh version 2.9.0 11/07/2018 with nmh-1.7.1 Reply-to: Cy Schubert From: Cy Schubert X-os: FreeBSD X-Sender: cy@cwsent.com X-URL: http://www.cschubert.com/ To: Mateusz Guzik cc: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: Re: git: b65ad70195d8 - main - cache: retire cache_fast_revlookup sysctl In-reply-to: <202108231334.17NDYHm1005889@gitrepo.freebsd.org> References: <202108231334.17NDYHm1005889@gitrepo.freebsd.org> Comments: In-reply-to Mateusz Guzik message dated "Mon, 23 Aug 2021 13:34:17 +0000." Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Mon, 23 Aug 2021 06:51:43 -0700 X-CMAE-Envelope: MS4xfPyTv4nB3oVS8uE9dDc9VdQMIGiu7HVabGntFmk7bA1a4ZU46Rj47S4+X68a89XC7qabidjfEAp0Y3LLdM1/HyDCM8yUdiZuWYFA2w3dr5Nt2I7w3wBh 33fVO+n5TChbUziro3v7AeYPWPq0P1uV51Igz34aKbYC1xd8jVJMW9vD+GA+/jtul+m41pSEhyGcN1+zaOpXEBqPM5TXVlwU11KYDQcSQ4ABaiUgAEwVuoZK HlK27ZinqzdOf/vnnKIbdvVRm9kcQQORTRJirc+kCwldsibO9bn95HzIoJ22tg9T7QqDcHPHi4j1lR0h5L4ylaD1BdLYVR0YfjHzL0gt9NM= X-Rspamd-Queue-Id: 4GtYZH5zwQz4RRY X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; none X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[] X-BeenThere: dev-commits-src-all@freebsd.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Commit messages for all branches of the src repository List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 23 Aug 2021 13:51:52 -0000 In message <202108231334.17NDYHm1005889@gitrepo.freebsd.org>, Mateusz Guzik wri tes: > The branch main has been updated by mjg: > > URL: https://cgit.FreeBSD.org/src/commit/?id=b65ad70195d874ac28e6e65d2fd8acf5 > d9a79236 > > commit b65ad70195d874ac28e6e65d2fd8acf5d9a79236 > Author: Mateusz Guzik > AuthorDate: 2021-08-23 13:29:42 +0000 > Commit: Mateusz Guzik > CommitDate: 2021-08-23 13:31:44 +0000 > > cache: retire cache_fast_revlookup sysctl Why? > > Sponsored by: Rubicon Communications, LLC ("Netgate") > --- > sys/kern/vfs_cache.c | 9 +++------ > 1 file changed, 3 insertions(+), 6 deletions(-) > > diff --git a/sys/kern/vfs_cache.c b/sys/kern/vfs_cache.c > index 199da865e39c..732dbbe53cef 100644 > --- a/sys/kern/vfs_cache.c > +++ b/sys/kern/vfs_cache.c > @@ -253,6 +253,8 @@ SDT_PROBE_DEFINE3(vfs, fplookup, lookup, done, "struct na > meidata", "int", "bool" > SDT_PROBE_DECLARE(vfs, namei, lookup, entry); > SDT_PROBE_DECLARE(vfs, namei, lookup, return); > > +static char __read_frequently cache_fast_lookup_enabled = true; > + > /* > * This structure describes the elements in the cache of recent > * names looked up by namei. > @@ -443,10 +445,6 @@ static u_long __exclusive_cache_line numcache;/* num > ber of cache entries allocat > > struct nchstats nchstats; /* cache effectiveness statisti > cs */ > > -static bool __read_frequently cache_fast_revlookup = true; > -SYSCTL_BOOL(_vfs, OID_AUTO, cache_fast_revlookup, CTLFLAG_RW, > - &cache_fast_revlookup, 0, ""); > - > static bool __read_mostly cache_rename_add = true; > SYSCTL_BOOL(_vfs, OID_AUTO, cache_rename_add, CTLFLAG_RW, > &cache_rename_add, 0, ""); > @@ -3440,7 +3438,7 @@ vn_fullpath_any_smr(struct vnode *vp, struct vnode *rdi > r, char *buf, > > VFS_SMR_ASSERT_ENTERED(); > > - if (!cache_fast_revlookup) { > + if (!atomic_load_char(&cache_fast_lookup_enabled)) { > vfs_smr_exit(); > return (-1); > } > @@ -3845,7 +3843,6 @@ DB_SHOW_COMMAND(vpath, db_show_vpath) > #endif > > static int cache_fast_lookup = 1; > -static char __read_frequently cache_fast_lookup_enabled = true; > > #define CACHE_FPL_FAILED -2020 > > -- Cheers, Cy Schubert FreeBSD UNIX: Web: https://FreeBSD.org NTP: Web: https://nwtime.org The need of the many outweighs the greed of the few.