From 6b3f6b5b87f03d1649340d6b3a572206653a2a2b Mon Sep 17 00:00:00 2001 From: Nathan Scott Date: Wed, 2 Nov 2005 15:08:25 +1100 Subject: [XFS] Rework the dquot hash sizing heuristics. SGI-PV: 943123 SGI-Modid: xfs-linux:xfs-kern:24012a Signed-off-by: Nathan Scott --- fs/xfs/quota/xfs_qm.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'fs/xfs/quota/xfs_qm.h') diff --git a/fs/xfs/quota/xfs_qm.h b/fs/xfs/quota/xfs_qm.h index 43219c97b37..12da259f2fc 100644 --- a/fs/xfs/quota/xfs_qm.h +++ b/fs/xfs/quota/xfs_qm.h @@ -26,6 +26,7 @@ struct xfs_qm; struct xfs_inode; +extern uint ndquot; extern mutex_t xfs_Gqm_lock; extern struct xfs_qm *xfs_Gqm; extern kmem_zone_t *qm_dqzone; @@ -51,9 +52,8 @@ extern kmem_zone_t *qm_dqtrxzone; /* * Dquot hashtable constants/threshold values. */ -#define XFS_QM_NCSIZE_THRESHOLD 5000 -#define XFS_QM_HASHSIZE_LOW 32 -#define XFS_QM_HASHSIZE_HIGH 64 +#define XFS_QM_HASHSIZE_LOW (NBPP / sizeof(xfs_dqhash_t)) +#define XFS_QM_HASHSIZE_HIGH ((NBPP * 4) / sizeof(xfs_dqhash_t)) /* * We output a cmn_err when quotachecking a quota file with more than -- cgit v1.2.3