-/* $OpenBSD: param.c,v 1.34 2012/04/10 15:50:52 guenther Exp $ */
+/* $OpenBSD: param.c,v 1.35 2015/01/09 05:01:56 tedu Exp $ */
/* $NetBSD: param.c,v 1.16 1996/03/12 03:08:40 mrg Exp $ */
/*
#define NPROCESS (30 + 16 * MAXUSERS)
#define NTEXT (80 + NPROCESS / 8) /* actually the object cache */
#define NVNODE (NPROCESS * 2 + NTEXT + 100)
-int desiredvnodes = NVNODE;
+int initialvnodes = NVNODE;
int maxprocess = NPROCESS;
int maxthread = NPROCESS + 8 * MAXUSERS;
int maxfiles = 5 * (NPROCESS + MAXUSERS) + 80;
-/* $OpenBSD: cd9660_node.c,v 1.27 2014/12/16 18:30:03 tedu Exp $ */
+/* $OpenBSD: cd9660_node.c,v 1.28 2015/01/09 05:01:56 tedu Exp $ */
/* $NetBSD: cd9660_node.c,v 1.17 1997/05/05 07:13:57 mycroft Exp $ */
/*-
struct vfsconf *vfsp;
{
- isohashtbl = hashinit(desiredvnodes, M_ISOFSMNT, M_WAITOK, &isohash);
+ isohashtbl = hashinit(initialvnodes, M_ISOFSMNT, M_WAITOK, &isohash);
arc4random_buf(&isohashkey, sizeof(isohashkey));
return (0);
}
-/* $OpenBSD: vfs_cache.c,v 1.41 2015/01/08 18:07:35 tedu Exp $ */
+/* $OpenBSD: vfs_cache.c,v 1.42 2015/01/09 05:01:56 tedu Exp $ */
/* $NetBSD: vfs_cache.c,v 1.13 1996/02/04 02:18:09 christos Exp $ */
/*
TAILQ_INSERT_TAIL(&nclruneghead, ncp, nc_neg);
numneg++;
}
- if (numneg > desiredvnodes) {
+ if (numneg > initialvnodes) {
if ((ncp = TAILQ_FIRST(&nclruneghead))
!= NULL)
cache_zap(ncp);
-/* $OpenBSD: vfs_subr.c,v 1.227 2014/12/19 05:59:21 tedu Exp $ */
+/* $OpenBSD: vfs_subr.c,v 1.228 2015/01/09 05:01:56 tedu Exp $ */
/* $NetBSD: vfs_subr.c,v 1.53 1996/04/22 01:39:13 christos Exp $ */
/*
vntblinit(void)
{
/* buffer cache may need a vnode for each buffer */
- maxvnodes = 2 * desiredvnodes;
+ maxvnodes = 2 * initialvnodes;
pool_init(&vnode_pool, sizeof(struct vnode), 0, 0, PR_WAITOK,
"vnodes", NULL);
pool_init(&uvm_vnode_pool, sizeof(struct uvm_vnode), 0, 0, PR_WAITOK,
-/* $OpenBSD: msdosfs_denode.c,v 1.52 2014/12/16 18:30:04 tedu Exp $ */
+/* $OpenBSD: msdosfs_denode.c,v 1.53 2015/01/09 05:01:57 tedu Exp $ */
/* $NetBSD: msdosfs_denode.c,v 1.23 1997/10/17 11:23:58 ws Exp $ */
/*-
int
msdosfs_init(struct vfsconf *vfsp)
{
- dehashtbl = hashinit(desiredvnodes/2, M_MSDOSFSMNT, M_WAITOK, &dehash);
+ dehashtbl = hashinit(initialvnodes / 2, M_MSDOSFSMNT, M_WAITOK, &dehash);
arc4random_buf(&dehashkey, sizeof(dehashkey));
return (0);
}
-/* $OpenBSD: ntfs_ihash.c,v 1.17 2014/11/18 10:42:15 dlg Exp $ */
+/* $OpenBSD: ntfs_ihash.c,v 1.18 2015/01/09 05:01:57 tedu Exp $ */
/* $NetBSD: ntfs_ihash.c,v 1.1 2002/12/23 17:38:32 jdolecek Exp $ */
/*
if (ntfs_nthashtbl)
return;
- nthashtbl = hashinit(desiredvnodes, M_NTFSNTHASH, M_WAITOK, &nthash);
+ nthashtbl = hashinit(initialvnodes, M_NTFSNTHASH, M_WAITOK, &nthash);
if (ntfs_nthashtbl) {
free(nthashtbl, M_NTFSNTHASH, 0);
return;
-/* $OpenBSD: vnode.h,v 1.128 2014/12/16 18:30:04 tedu Exp $ */
+/* $OpenBSD: vnode.h,v 1.129 2015/01/09 05:01:57 tedu Exp $ */
/* $NetBSD: vnode.h,v 1.38 1996/02/29 20:59:05 cgd Exp $ */
/*
* Global vnode data.
*/
extern struct vnode *rootvnode; /* root (i.e. "/") vnode */
-extern int desiredvnodes; /* XXX number of vnodes desired */
+extern int initialvnodes; /* XXX number of vnodes to start */
extern int maxvnodes; /* XXX number of vnodes to allocate */
extern int syncdelay; /* seconds to delay syncing vnodes */
extern int rushjob; /* # of slots syncer should run ASAP */
-/* $OpenBSD: ffs_softdep.c,v 1.130 2014/12/23 01:53:34 tedu Exp $ */
+/* $OpenBSD: ffs_softdep.c,v 1.131 2015/01/09 05:01:57 tedu Exp $ */
/*
* Copyright 1998, 2000 Marshall Kirk McKusick. All Rights Reserved.
LIST_INIT(&mkdirlisthd);
LIST_INIT(&softdep_workitem_pending);
#ifdef KMEMSTATS
- max_softdeps = min (desiredvnodes * 8,
+ max_softdeps = min (initialvnodes * 8,
kmemstats[M_INODEDEP].ks_limit / (2 * sizeof(struct inodedep)));
#else
- max_softdeps = desiredvnodes * 4;
+ max_softdeps = initialvnodes * 4;
#endif
arc4random_buf(&softdep_hashkey, sizeof(softdep_hashkey));
- pagedep_hashtbl = hashinit(desiredvnodes / 5, M_PAGEDEP, M_WAITOK,
+ pagedep_hashtbl = hashinit(initialvnodes / 5, M_PAGEDEP, M_WAITOK,
&pagedep_hash);
sema_init(&pagedep_in_progress, "pagedep", PRIBIO, 0);
- inodedep_hashtbl = hashinit(desiredvnodes, M_INODEDEP, M_WAITOK,
+ inodedep_hashtbl = hashinit(initialvnodes, M_INODEDEP, M_WAITOK,
&inodedep_hash);
sema_init(&inodedep_in_progress, "inodedep", PRIBIO, 0);
newblk_hashtbl = hashinit(64, M_NEWBLK, M_WAITOK, &newblk_hash);
-/* $OpenBSD: ufs_ihash.c,v 1.20 2014/11/17 00:59:31 dlg Exp $ */
+/* $OpenBSD: ufs_ihash.c,v 1.21 2015/01/09 05:01:57 tedu Exp $ */
/* $NetBSD: ufs_ihash.c,v 1.3 1996/02/09 22:36:04 christos Exp $ */
/*
void
ufs_ihashinit(void)
{
- ihashtbl = hashinit(desiredvnodes, M_UFSMNT, M_WAITOK, &ihash);
+ ihashtbl = hashinit(initialvnodes, M_UFSMNT, M_WAITOK, &ihash);
arc4random_buf(&ihashkey, sizeof(ihashkey));
}
-/* $OpenBSD: ufs_quota.c,v 1.36 2014/11/18 10:42:15 dlg Exp $ */
+/* $OpenBSD: ufs_quota.c,v 1.37 2015/01/09 05:01:57 tedu Exp $ */
/* $NetBSD: ufs_quota.c,v 1.8 1996/02/09 22:36:09 christos Exp $ */
/*
void
ufs_quota_init(void)
{
- dqhashtbl = hashinit(desiredvnodes, M_DQUOT, M_WAITOK, &dqhash);
+ dqhashtbl = hashinit(initialvnodes, M_DQUOT, M_WAITOK, &dqhash);
arc4random_buf(&dqhashkey, sizeof(dqhashkey));
TAILQ_INIT(&dqfreelist);
}
* Not in cache, allocate a new one.
*/
if (TAILQ_FIRST(&dqfreelist) == NODQUOT &&
- numdquot < MAXQUOTAS * desiredvnodes)
+ numdquot < MAXQUOTAS * initialvnodes)
desireddquot += DQUOTINC;
if (numdquot < desireddquot) {
dq = malloc(sizeof *dq, M_DQUOT, M_WAITOK | M_ZERO);