From owner-cvs-sys Sat Mar 8 07:22:19 1997 Return-Path: Received: (from root@localhost) by freefall.freebsd.org (8.8.5/8.8.5) id HAA17774 for cvs-sys-outgoing; Sat, 8 Mar 1997 07:22:19 -0800 (PST) Received: (from bde@localhost) by freefall.freebsd.org (8.8.5/8.8.5) id HAA17765; Sat, 8 Mar 1997 07:22:17 -0800 (PST) Date: Sat, 8 Mar 1997 07:22:17 -0800 (PST) From: Bruce Evans Message-Id: <199703081522.HAA17765@freefall.freebsd.org> To: CVS-committers, cvs-all, cvs-sys Subject: cvs commit: src/sys/kern vfs_cache.c Sender: owner-cvs-sys@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk bde 97/03/08 07:22:16 Modified: sys/kern vfs_cache.c Log: Fixed the hash formula. Lite2 doesn't have phashinit(), so Lite2's hash formula uses `& nchash'. This is very broken when nchash is a prime number instead of 1 less than a power of 2, but the Lite2 formula was merged in. Merged some cosmetic changes from Lite2, rev.1.21 and Lite1. The merge was difficult because the Lite2 code is essentially ours (phk's) except where Lite2 improved or broke it. Summary of the Lite2 changes: - in the copyright, phk's rights have been transferred to the Regents. This change should be reviewed. - nchENOENT went away; the "no" vnode is now simply 0. - comments were improved. - style was "improved". - goto instead of Fanatism (sic) was considered bad :-). - there are some small changes to support whiteouts. - new cache entries are added in more cases. More work is required near here to change the hash table size if kern.desiredvnodes is changed using sysctl. - rescanning of the hash bucket in cache_purgevfs() was removed. This change should be reviewed. Revision Changes Path 1.24 +14 -14 src/sys/kern/vfs_cache.c