summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorthib <thib@openbsd.org>2008-06-15 04:03:40 +0000
committerthib <thib@openbsd.org>2008-06-15 04:03:40 +0000
commitcfd2d49a6e2cb99bfc8865964c5047ed96b61d8d (patch)
tree4e3db42a777e5f7e18e9f7d61c57475550275715
parentfix filehandle comparison between NFSv2 and NFSv3 filehandles (diff)
downloadwireguard-openbsd-cfd2d49a6e2cb99bfc8865964c5047ed96b61d8d.tar.xz
wireguard-openbsd-cfd2d49a6e2cb99bfc8865964c5047ed96b61d8d.zip
unroll the NFSMADV() macro and nuke it
ok blambert@
-rw-r--r--sys/nfs/nfs_serv.c6
-rw-r--r--sys/nfs/nfs_subs.c4
-rw-r--r--sys/nfs/nfsm_subs.h3
3 files changed, 6 insertions, 7 deletions
diff --git a/sys/nfs/nfs_serv.c b/sys/nfs/nfs_serv.c
index ce08e07972e..f386ced1f03 100644
--- a/sys/nfs/nfs_serv.c
+++ b/sys/nfs/nfs_serv.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: nfs_serv.c,v 1.56 2008/06/14 22:44:07 blambert Exp $ */
+/* $OpenBSD: nfs_serv.c,v 1.57 2008/06/15 04:03:40 thib Exp $ */
/* $NetBSD: nfs_serv.c,v 1.34 1997/05/12 23:37:12 fvdl Exp $ */
/*
@@ -725,7 +725,7 @@ nfsrv_write(nfsd, slp, procp, mrq)
adjust = dpos - mtod(mp, caddr_t);
mp->m_len -= adjust;
if (mp->m_len > 0 && adjust > 0)
- NFSMADV(mp, adjust);
+ mp->m_data += adjust;
}
if (zeroing)
mp->m_len = 0;
@@ -920,7 +920,7 @@ nfsrv_writegather(ndp, slp, procp, mrq)
adjust = dpos - mtod(mp, caddr_t);
mp->m_len -= adjust;
if (mp->m_len > 0 && adjust > 0)
- NFSMADV(mp, adjust);
+ mp->m_data += adjust;
}
if (zeroing)
mp->m_len = 0;
diff --git a/sys/nfs/nfs_subs.c b/sys/nfs/nfs_subs.c
index d281a1a2145..f276fbbed0e 100644
--- a/sys/nfs/nfs_subs.c
+++ b/sys/nfs/nfs_subs.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: nfs_subs.c,v 1.83 2008/06/14 00:26:13 thib Exp $ */
+/* $OpenBSD: nfs_subs.c,v 1.84 2008/06/15 04:03:40 thib Exp $ */
/* $NetBSD: nfs_subs.c,v 1.27.4.3 1996/07/08 20:34:24 jtc Exp $ */
/*
@@ -866,7 +866,7 @@ nfsm_disct(mdp, dposp, siz, left, cp2)
xfer = (siz2 > mp2->m_len) ? mp2->m_len : siz2;
if (xfer > 0) {
bcopy(mtod(mp2, caddr_t), p, xfer);
- NFSMADV(mp2, xfer);
+ mp2->m_data += xfer;
mp2->m_len -= xfer;
p += xfer;
siz2 -= xfer;
diff --git a/sys/nfs/nfsm_subs.h b/sys/nfs/nfsm_subs.h
index c2aa61b97e6..debd07f01c2 100644
--- a/sys/nfs/nfsm_subs.h
+++ b/sys/nfs/nfsm_subs.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: nfsm_subs.h,v 1.30 2008/06/14 22:44:07 blambert Exp $ */
+/* $OpenBSD: nfsm_subs.h,v 1.31 2008/06/15 04:03:40 thib Exp $ */
/* $NetBSD: nfsm_subs.h,v 1.10 1996/03/20 21:59:56 fvdl Exp $ */
/*
@@ -51,7 +51,6 @@
*/
#define M_HASCL(m) ((m)->m_flags & M_EXT)
-#define NFSMADV(m, s) (m)->m_data += (s)
#define NFSMSIZ(m) ((M_HASCL(m)) ? (m)->m_ext.ext_size : \
(((m)->m_flags & M_PKTHDR) ? MHLEN : MLEN))