diff options
Diffstat (limited to 'sys/nfs/nfs_node.c')
| -rw-r--r-- | sys/nfs/nfs_node.c | 24 |
1 files changed, 4 insertions, 20 deletions
diff --git a/sys/nfs/nfs_node.c b/sys/nfs/nfs_node.c index 4b4294ae434..f4d24471f4f 100644 --- a/sys/nfs/nfs_node.c +++ b/sys/nfs/nfs_node.c @@ -1,4 +1,4 @@ -/* $OpenBSD: nfs_node.c,v 1.24 2002/03/14 01:27:13 millert Exp $ */ +/* $OpenBSD: nfs_node.c,v 1.25 2002/07/02 04:23:25 ericj Exp $ */ /* $NetBSD: nfs_node.c,v 1.16 1996/02/18 11:53:42 fvdl Exp $ */ /* @@ -49,6 +49,7 @@ #include <sys/kernel.h> #include <sys/malloc.h> #include <sys/pool.h> +#include <sys/hash.h> #include <nfs/rpcv2.h> #include <nfs/nfsproto.h> @@ -68,6 +69,8 @@ extern int prtactive; #define TRUE 1 #define FALSE 0 +#define nfs_hash(x,y) hash32_buf((x), (y), HASHINIT) + /* * Initialize hash links for nfsnodes * and build nfsnode free list. @@ -83,25 +86,6 @@ nfs_nhinit() } /* - * Compute an entry in the NFS hash table structure - */ -u_long -nfs_hash(fhp, fhsize) - nfsfh_t *fhp; - int fhsize; -{ - u_char *fhpp; - u_long fhsum; - int i; - - fhpp = &fhp->fh_bytes[0]; - fhsum = 0; - for (i = 0; i < fhsize; i++) - fhsum += *fhpp++; - return (fhsum); -} - -/* * Look up a vnode/nfsnode by file handle. * Callers must check for mount points!! * In all cases, a pointer to a |
