mirror of
https://github.com/opnsense/src.git
synced 2026-06-08 00:02:14 -04:00
vfs cache: Drop known argument of internal cache_recalc_neg_min()
'ncnegminpct' is to be passed always, so just drop the unneeded parameter. Sponsored by: The FreeBSD Foundation Reviewed by: mjg Differential Revision: https://reviews.freebsd.org/D41763
This commit is contained in:
parent
02cbc029da
commit
02ef039c28
1 changed files with 5 additions and 5 deletions
|
|
@ -990,10 +990,10 @@ SYSCTL_PROC(_vfs_cache, OID_AUTO, nchstats, CTLTYPE_OPAQUE | CTLFLAG_RD |
|
|||
"VFS cache effectiveness statistics");
|
||||
|
||||
static void
|
||||
cache_recalc_neg_min(u_int val)
|
||||
cache_recalc_neg_min(void)
|
||||
{
|
||||
|
||||
neg_min = (ncsize * val) / 100;
|
||||
neg_min = (ncsize * ncnegminpct) / 100;
|
||||
}
|
||||
|
||||
static int
|
||||
|
|
@ -1012,7 +1012,7 @@ sysctl_negminpct(SYSCTL_HANDLER_ARGS)
|
|||
if (val < 0 || val > 99)
|
||||
return (EINVAL);
|
||||
ncnegminpct = val;
|
||||
cache_recalc_neg_min(val);
|
||||
cache_recalc_neg_min();
|
||||
return (0);
|
||||
}
|
||||
|
||||
|
|
@ -2652,7 +2652,7 @@ nchinit(void *dummy __unused)
|
|||
VFS_SMR_ZONE_SET(cache_zone_large_ts);
|
||||
|
||||
ncsize = desiredvnodes * ncsizefactor;
|
||||
cache_recalc_neg_min(ncnegminpct);
|
||||
cache_recalc_neg_min();
|
||||
nchashtbl = nchinittbl(desiredvnodes * 2, &nchash);
|
||||
ncbuckethash = cache_roundup_2(mp_ncpus * mp_ncpus) - 1;
|
||||
if (ncbuckethash < 7) /* arbitrarily chosen to avoid having one lock */
|
||||
|
|
@ -2796,7 +2796,7 @@ cache_changesize(u_long newmaxvnodes)
|
|||
}
|
||||
}
|
||||
ncsize = newncsize;
|
||||
cache_recalc_neg_min(ncnegminpct);
|
||||
cache_recalc_neg_min();
|
||||
cache_changesize_set_new(new_nchashtbl, new_nchash);
|
||||
cache_unlock_all_buckets();
|
||||
cache_unlock_all_vnodes();
|
||||
|
|
|
|||
Loading…
Reference in a new issue