summaryrefslogtreecommitdiffstats
path: root/sys/nfsserver/nfs.h
diff options
context:
space:
mode:
authorrwatson <rwatson@FreeBSD.org>2005-04-17 16:25:36 +0000
committerrwatson <rwatson@FreeBSD.org>2005-04-17 16:25:36 +0000
commit21db4509f19b64c38dc37f169d191a7f19f96c44 (patch)
treed5b0372bf78e63f7be4c51e355a14a4a454f49dd /sys/nfsserver/nfs.h
parent1f1f3e731fe1d0d19b0496208b0209637244c85e (diff)
downloadFreeBSD-src-21db4509f19b64c38dc37f169d191a7f19f96c44.zip
FreeBSD-src-21db4509f19b64c38dc37f169d191a7f19f96c44.tar.gz
NFS write gathering defers execution of NFS server write requests to wait
to see if additional write requests will arrive that can be coalesced and clustered with earlier ones. When doing so, it must determine whether the two requests are made by credentials with the same access writes, so as not to coalesce improperly. NFSW_SAMECRED() implements a test of two credentials using a binary compare. Replace NFSW_SAMECRED() macro with nfsrv_samecred() function, which is aware of the contents and layout of a struct ucred, rather than a simple binary compare. While the binary compare works when ucred is simply a zero'd and embedded 'struct ucred' in the NFS descriptor, it will work less well when the ucred associated with an NFS descriptor is "real", so has defined and populated reference count, mutex, etc. MFC after: 1 week Obtained from: TrustedBSD Project
Diffstat (limited to 'sys/nfsserver/nfs.h')
-rw-r--r--sys/nfsserver/nfs.h4
1 files changed, 0 insertions, 4 deletions
diff --git a/sys/nfsserver/nfs.h b/sys/nfsserver/nfs.h
index 07ba71a..e8d5d21 100644
--- a/sys/nfsserver/nfs.h
+++ b/sys/nfsserver/nfs.h
@@ -275,10 +275,6 @@ extern int nfsd_head_flag;
((o)->nd_eoff >= (n)->nd_off && \
!bcmp((caddr_t)&(o)->nd_fh, (caddr_t)&(n)->nd_fh, NFSX_V3FH))
-#define NFSW_SAMECRED(o, n) \
- (!bcmp((caddr_t)&(o)->nd_cr, (caddr_t)&(n)->nd_cr, \
- sizeof (struct ucred)))
-
/*
* Defines for WebNFS
*/
OpenPOWER on IntegriCloud