svn commit: r362639 - in head/sys/fs: nfs nfsclient nfsserver
Rick Macklem
rmacklem at FreeBSD.org
Fri Jun 26 03:11:56 UTC 2020
Author: rmacklem
Date: Fri Jun 26 03:11:54 2020
New Revision: 362639
URL: https://svnweb.freebsd.org/changeset/base/362639
Log:
Add a boolean argument to nfscl_reqstart() to indicate that ext_pgs mbufs
should be used.
For KERN_TLS (and possibly some other future network interface) the mbuf
list passed into sosend() must be ext_pgs mbufs. The krpc could simply
copy all the mbuf data into ext_pgs mbufs before calling sosend(), but
that would be inefficient for large RPC messages.
This patch adds an argument to nfscl_reqstart() to indicate that it should
fill the RPC message into ext_pgs mbufs.
It also adds fields to "struct nfsrv_descript" needed for building NFS RPC
messages in ext_pgs mbufs, along with new flags for this.
Since the argument is always "false", this commit should not result in any
semantic change. However, this commit prepares the code
for future commits that will add support for building of NFS RPC messages
in ext_pgs mbufs.
Modified:
head/sys/fs/nfs/nfs.h
head/sys/fs/nfs/nfs_commonsubs.c
head/sys/fs/nfs/nfs_var.h
head/sys/fs/nfs/nfscl.h
head/sys/fs/nfsclient/nfs_clrpcops.c
head/sys/fs/nfsserver/nfs_nfsdport.c
Modified: head/sys/fs/nfs/nfs.h
==============================================================================
--- head/sys/fs/nfs/nfs.h Fri Jun 26 00:58:59 2020 (r362638)
+++ head/sys/fs/nfs/nfs.h Fri Jun 26 03:11:54 2020 (r362639)
@@ -670,6 +670,9 @@ struct nfsrv_descript {
nfsv4stateid_t nd_savedcurstateid; /* Saved Current StateID */
uint32_t nd_maxreq; /* Max. request (session). */
uint32_t nd_maxresp; /* Max. reply (session). */
+ int nd_bextpg; /* Current ext_pgs page */
+ int nd_bextpgsiz; /* Bytes left in page */
+ int nd_maxextsiz; /* Max ext_pgs mbuf size */
};
#define nd_princlen nd_gssnamelen
@@ -711,6 +714,13 @@ struct nfsrv_descript {
#define ND_SAVEDCURSTATEID 0x100000000
#define ND_HASSLOTID 0x200000000
#define ND_NFSV42 0x400000000
+#define ND_EXTPG 0x800000000
+#define ND_TLS 0x1000000000
+#define ND_TLSCERT 0x2000000000
+#define ND_TLSCERTUSER 0x4000000000
+#define ND_EXTLS 0x8000000000
+#define ND_EXTLSCERT 0x10000000000
+#define ND_EXTLSCERTUSER 0x20000000000
/*
* ND_GSS should be the "or" of all GSS type authentications.
Modified: head/sys/fs/nfs/nfs_commonsubs.c
==============================================================================
--- head/sys/fs/nfs/nfs_commonsubs.c Fri Jun 26 00:58:59 2020 (r362638)
+++ head/sys/fs/nfs/nfs_commonsubs.c Fri Jun 26 03:11:54 2020 (r362639)
@@ -50,6 +50,8 @@ __FBSDID("$FreeBSD$");
#include <security/mac/mac_framework.h>
+#include <vm/vm_param.h>
+
/*
* Data items converted to xdr at startup, since they are constant
* This is kinda hokey, but may save a little time doing byte swaps
@@ -317,7 +319,7 @@ static int nfs_bigrequest[NFSV42_NPROCS] = {
void
nfscl_reqstart(struct nfsrv_descript *nd, int procnum, struct nfsmount *nmp,
u_int8_t *nfhp, int fhlen, u_int32_t **opcntpp, struct nfsclsession *sep,
- int vers, int minorvers)
+ int vers, int minorvers, bool use_ext)
{
struct mbuf *mb;
u_int32_t *tl;
@@ -350,6 +352,9 @@ nfscl_reqstart(struct nfsrv_descript *nd, int procnum,
}
nd->nd_procnum = procnum;
nd->nd_repstat = 0;
+ nd->nd_maxextsiz = 16384;
+ if (use_ext && mb_use_ext_pgs && PMAP_HAS_DMAP != 0)
+ nd->nd_flag |= ND_EXTPG;
/*
* Get the first mbuf for the request.
@@ -360,7 +365,7 @@ nfscl_reqstart(struct nfsrv_descript *nd, int procnum,
NFSMGET(mb);
mb->m_len = 0;
nd->nd_mreq = nd->nd_mb = mb;
- nd->nd_bpos = mtod(mb, caddr_t);
+ nd->nd_bpos = mtod(mb, char *);
/*
* And fill the first file handle into the request.
Modified: head/sys/fs/nfs/nfs_var.h
==============================================================================
--- head/sys/fs/nfs/nfs_var.h Fri Jun 26 00:58:59 2020 (r362638)
+++ head/sys/fs/nfs/nfs_var.h Fri Jun 26 03:11:54 2020 (r362639)
@@ -312,7 +312,7 @@ void nfsrc_trimcache(uint64_t, uint32_t, int);
/* nfs_commonsubs.c */
void nfscl_reqstart(struct nfsrv_descript *, int, struct nfsmount *,
- u_int8_t *, int, u_int32_t **, struct nfsclsession *, int, int);
+ u_int8_t *, int, u_int32_t **, struct nfsclsession *, int, int, bool);
void nfsm_stateidtom(struct nfsrv_descript *, nfsv4stateid_t *, int);
void nfscl_fillsattr(struct nfsrv_descript *, struct vattr *,
vnode_t, int, u_int32_t);
Modified: head/sys/fs/nfs/nfscl.h
==============================================================================
--- head/sys/fs/nfs/nfscl.h Fri Jun 26 00:58:59 2020 (r362638)
+++ head/sys/fs/nfs/nfscl.h Fri Jun 26 03:11:54 2020 (r362639)
@@ -52,7 +52,7 @@ struct nfsv4node {
#define NFSCL_REQSTART(n, p, v) \
nfscl_reqstart((n), (p), VFSTONFS((v)->v_mount), \
VTONFS(v)->n_fhp->nfh_fh, VTONFS(v)->n_fhp->nfh_len, NULL, \
- NULL, 0, 0)
+ NULL, 0, 0, false)
/*
* These two macros convert between a lease duration and renew interval.
Modified: head/sys/fs/nfsclient/nfs_clrpcops.c
==============================================================================
--- head/sys/fs/nfsclient/nfs_clrpcops.c Fri Jun 26 00:58:59 2020 (r362638)
+++ head/sys/fs/nfsclient/nfs_clrpcops.c Fri Jun 26 03:11:54 2020 (r362639)
@@ -499,7 +499,8 @@ nfsrpc_openrpc(struct nfsmount *nmp, vnode_t vp, u_int
dp = *dpp;
*dpp = NULL;
- nfscl_reqstart(nd, NFSPROC_OPEN, nmp, nfhp, fhlen, NULL, NULL, 0, 0);
+ nfscl_reqstart(nd, NFSPROC_OPEN, nmp, nfhp, fhlen, NULL, NULL, 0, 0,
+ false);
NFSM_BUILD(tl, u_int32_t *, 5 * NFSX_UNSIGNED);
*tl++ = txdr_unsigned(op->nfso_own->nfsow_seqid);
*tl++ = txdr_unsigned(mode & NFSV4OPEN_ACCESSBOTH);
@@ -855,7 +856,7 @@ nfsrpc_closerpc(struct nfsrv_descript *nd, struct nfsm
int error;
nfscl_reqstart(nd, NFSPROC_CLOSE, nmp, op->nfso_fh,
- op->nfso_fhlen, NULL, NULL, 0, 0);
+ op->nfso_fhlen, NULL, NULL, 0, 0, false);
NFSM_BUILD(tl, u_int32_t *, NFSX_UNSIGNED + NFSX_STATEID);
*tl++ = txdr_unsigned(op->nfso_own->nfsow_seqid);
if (NFSHASNFSV4N(nmp))
@@ -898,7 +899,7 @@ nfsrpc_openconfirm(vnode_t vp, u_int8_t *nfhp, int fhl
if (NFSHASNFSV4N(nmp))
return (0); /* No confirmation for NFSv4.1. */
nfscl_reqstart(nd, NFSPROC_OPENCONFIRM, nmp, nfhp, fhlen, NULL, NULL,
- 0, 0);
+ 0, 0, false);
NFSM_BUILD(tl, u_int32_t *, NFSX_UNSIGNED + NFSX_STATEID);
*tl++ = op->nfso_stateid.seqid;
*tl++ = op->nfso_stateid.other[0];
@@ -1068,7 +1069,8 @@ nfsrpc_setclient(struct nfsmount *nmp, struct nfsclcli
tsep = NFSMNT_MDSSESSION(nmp);
NFSUNLOCKMNT(nmp);
- nfscl_reqstart(nd, NFSPROC_SETCLIENTID, nmp, NULL, 0, NULL, NULL, 0, 0);
+ nfscl_reqstart(nd, NFSPROC_SETCLIENTID, nmp, NULL, 0, NULL, NULL, 0, 0,
+ false);
NFSM_BUILD(tl, u_int32_t *, 2 * NFSX_UNSIGNED);
*tl++ = txdr_unsigned(nfsboottime.tv_sec);
*tl = txdr_unsigned(clp->nfsc_rev);
@@ -1138,7 +1140,7 @@ nfsrpc_setclient(struct nfsmount *nmp, struct nfsclcli
* and confirm it.
*/
nfscl_reqstart(nd, NFSPROC_SETCLIENTIDCFRM, nmp, NULL, 0, NULL,
- NULL, 0, 0);
+ NULL, 0, 0, false);
NFSM_BUILD(tl, u_int32_t *, 4 * NFSX_UNSIGNED);
*tl++ = tsep->nfsess_clientid.lval[0];
*tl++ = tsep->nfsess_clientid.lval[1];
@@ -1153,7 +1155,7 @@ nfsrpc_setclient(struct nfsmount *nmp, struct nfsclcli
nd->nd_mrep = NULL;
if (nd->nd_repstat == 0) {
nfscl_reqstart(nd, NFSPROC_GETATTR, nmp, nmp->nm_fh,
- nmp->nm_fhsize, NULL, NULL, 0, 0);
+ nmp->nm_fhsize, NULL, NULL, 0, 0, false);
NFSZERO_ATTRBIT(&attrbits);
NFSSETBIT_ATTRBIT(&attrbits, NFSATTRBIT_LEASETIME);
(void) nfsrv_putattrbit(nd, &attrbits);
@@ -1220,7 +1222,8 @@ nfsrpc_getattrnovp(struct nfsmount *nmp, u_int8_t *fhp
int error, vers = NFS_VER2;
nfsattrbit_t attrbits;
- nfscl_reqstart(nd, NFSPROC_GETATTR, nmp, fhp, fhlen, NULL, NULL, 0, 0);
+ nfscl_reqstart(nd, NFSPROC_GETATTR, nmp, fhp, fhlen, NULL, NULL, 0, 0,
+ false);
if (nd->nd_flag & ND_NFSV4) {
vers = NFS_VER4;
NFSGETATTR_ATTRBIT(&attrbits);
@@ -4162,7 +4165,7 @@ nfsrpc_locku(struct nfsrv_descript *nd, struct nfsmoun
int error;
nfscl_reqstart(nd, NFSPROC_LOCKU, nmp, lp->nfsl_open->nfso_fh,
- lp->nfsl_open->nfso_fhlen, NULL, NULL, 0, 0);
+ lp->nfsl_open->nfso_fhlen, NULL, NULL, 0, 0, false);
NFSM_BUILD(tl, u_int32_t *, NFSX_STATEID + 6 * NFSX_UNSIGNED);
*tl++ = txdr_unsigned(type);
*tl = txdr_unsigned(lp->nfsl_seqid);
@@ -4214,7 +4217,8 @@ nfsrpc_lock(struct nfsrv_descript *nd, struct nfsmount
uint8_t own[NFSV4CL_LOCKNAMELEN + NFSX_V4FHMAX];
struct nfsclsession *tsep;
- nfscl_reqstart(nd, NFSPROC_LOCK, nmp, nfhp, fhlen, NULL, NULL, 0, 0);
+ nfscl_reqstart(nd, NFSPROC_LOCK, nmp, nfhp, fhlen, NULL, NULL, 0, 0,
+ false);
NFSM_BUILD(tl, u_int32_t *, 7 * NFSX_UNSIGNED);
if (type == F_RDLCK)
*tl++ = txdr_unsigned(NFSV4LOCKT_READ);
@@ -4488,10 +4492,10 @@ nfsrpc_renew(struct nfsclclient *clp, struct nfsclds *
return (0);
if (dsp == NULL)
nfscl_reqstart(nd, NFSPROC_RENEW, nmp, NULL, 0, NULL, NULL, 0,
- 0);
+ 0, false);
else
nfscl_reqstart(nd, NFSPROC_RENEW, nmp, NULL, 0, NULL,
- &dsp->nfsclds_sess, 0, 0);
+ &dsp->nfsclds_sess, 0, 0, false);
if (!NFSHASNFSV4N(nmp)) {
/* NFSv4.1 just uses a Sequence Op and not a Renew. */
NFSM_BUILD(tl, u_int32_t *, 2 * NFSX_UNSIGNED);
@@ -4538,11 +4542,11 @@ nfsrpc_rellockown(struct nfsmount *nmp, struct nfscllo
if (NFSHASNFSV4N(nmp)) {
/* For NFSv4.1, do a FreeStateID. */
nfscl_reqstart(nd, NFSPROC_FREESTATEID, nmp, NULL, 0, NULL,
- NULL, 0, 0);
+ NULL, 0, 0, false);
nfsm_stateidtom(nd, &lp->nfsl_stateid, NFSSTATEID_PUTSTATEID);
} else {
nfscl_reqstart(nd, NFSPROC_RELEASELCKOWN, nmp, NULL, 0, NULL,
- NULL, 0, 0);
+ NULL, 0, 0, false);
NFSM_BUILD(tl, u_int32_t *, 2 * NFSX_UNSIGNED);
tsep = nfsmnt_mdssession(nmp);
*tl++ = tsep->nfsess_clientid.lval[0];
@@ -4576,7 +4580,7 @@ nfsrpc_getdirpath(struct nfsmount *nmp, u_char *dirpat
u_int32_t *opcntp;
nfscl_reqstart(nd, NFSPROC_PUTROOTFH, nmp, NULL, 0, &opcntp, NULL, 0,
- 0);
+ 0, false);
cp = dirpath;
cnt = 0;
do {
@@ -4643,7 +4647,7 @@ nfsrpc_delegreturn(struct nfscldeleg *dp, struct ucred
int error;
nfscl_reqstart(nd, NFSPROC_DELEGRETURN, nmp, dp->nfsdl_fh,
- dp->nfsdl_fhlen, NULL, NULL, 0, 0);
+ dp->nfsdl_fhlen, NULL, NULL, 0, 0, false);
NFSM_BUILD(tl, u_int32_t *, NFSX_STATEID);
if (NFSHASNFSV4N(nmp))
*tl++ = 0;
@@ -4756,7 +4760,7 @@ nfsrpc_exchangeid(struct nfsmount *nmp, struct nfsclcl
if (minorvers == 0)
minorvers = nmp->nm_minorvers;
nfscl_reqstart(nd, NFSPROC_EXCHANGEID, nmp, NULL, 0, NULL, NULL,
- NFS_VER4, minorvers);
+ NFS_VER4, minorvers, false);
NFSM_BUILD(tl, uint32_t *, 2 * NFSX_UNSIGNED);
*tl++ = txdr_unsigned(nfsboottime.tv_sec); /* Client owner */
*tl = txdr_unsigned(clp->nfsc_rev);
@@ -4852,7 +4856,7 @@ nfsrpc_createsession(struct nfsmount *nmp, struct nfsc
else
minorvers = NFSV41_MINORVERSION;
nfscl_reqstart(nd, NFSPROC_CREATESESSION, nmp, NULL, 0, NULL, NULL,
- NFS_VER4, minorvers);
+ NFS_VER4, minorvers, false);
NFSM_BUILD(tl, uint32_t *, 4 * NFSX_UNSIGNED);
*tl++ = sep->nfsess_clientid.lval[0];
*tl++ = sep->nfsess_clientid.lval[1];
@@ -4979,7 +4983,7 @@ nfsrpc_destroysession(struct nfsmount *nmp, struct nfs
struct nfsclsession *tsep;
nfscl_reqstart(nd, NFSPROC_DESTROYSESSION, nmp, NULL, 0, NULL, NULL, 0,
- 0);
+ 0, false);
NFSM_BUILD(tl, uint32_t *, NFSX_V4SESSIONID);
tsep = nfsmnt_mdssession(nmp);
bcopy(tsep->nfsess_sessionid, tl, NFSX_V4SESSIONID);
@@ -5007,7 +5011,7 @@ nfsrpc_destroyclient(struct nfsmount *nmp, struct nfsc
struct nfsclsession *tsep;
nfscl_reqstart(nd, NFSPROC_DESTROYCLIENT, nmp, NULL, 0, NULL, NULL, 0,
- 0);
+ 0, false);
NFSM_BUILD(tl, uint32_t *, 2 * NFSX_UNSIGNED);
tsep = nfsmnt_mdssession(nmp);
*tl++ = tsep->nfsess_clientid.lval[0];
@@ -5036,7 +5040,7 @@ nfsrpc_layoutget(struct nfsmount *nmp, uint8_t *fhp, i
int error;
nfscl_reqstart(nd, NFSPROC_LAYOUTGET, nmp, fhp, fhlen, NULL, NULL, 0,
- 0);
+ 0, false);
nfsrv_setuplayoutget(nd, iomode, offset, len, minlen, stateidp,
layouttype, layoutlen, 0);
nd->nd_flag |= ND_USEGSSNAME;
@@ -5080,7 +5084,7 @@ nfsrpc_getdeviceinfo(struct nfsmount *nmp, uint8_t *de
ndi = NULL;
gotdspp = NULL;
nfscl_reqstart(nd, NFSPROC_GETDEVICEINFO, nmp, NULL, 0, NULL, NULL, 0,
- 0);
+ 0, false);
NFSM_BUILD(tl, uint32_t *, NFSX_V4DEVICEID + 3 * NFSX_UNSIGNED);
NFSBCOPY(deviceid, tl, NFSX_V4DEVICEID);
tl += (NFSX_V4DEVICEID / NFSX_UNSIGNED);
@@ -5301,7 +5305,7 @@ nfsrpc_layoutcommit(struct nfsmount *nmp, uint8_t *fh,
int error;
nfscl_reqstart(nd, NFSPROC_LAYOUTCOMMIT, nmp, fh, fhlen, NULL, NULL,
- 0, 0);
+ 0, 0, false);
NFSM_BUILD(tl, uint32_t *, 5 * NFSX_UNSIGNED + 3 * NFSX_HYPER +
NFSX_STATEID);
txdr_hyper(off, tl);
@@ -5352,7 +5356,7 @@ nfsrpc_layoutreturn(struct nfsmount *nmp, uint8_t *fh,
int error;
nfscl_reqstart(nd, NFSPROC_LAYOUTRETURN, nmp, fh, fhlen, NULL, NULL,
- 0, 0);
+ 0, 0, false);
NFSM_BUILD(tl, uint32_t *, 4 * NFSX_UNSIGNED);
if (reclaim != 0)
*tl++ = newnfs_true;
@@ -5709,7 +5713,7 @@ nfsrpc_reclaimcomplete(struct nfsmount *nmp, struct uc
int error;
nfscl_reqstart(nd, NFSPROC_RECLAIMCOMPL, nmp, NULL, 0, NULL, NULL, 0,
- 0);
+ 0, false);
NFSM_BUILD(tl, uint32_t *, NFSX_UNSIGNED);
*tl = newnfs_false;
nd->nd_flag |= ND_USEGSSNAME;
@@ -6300,7 +6304,8 @@ nfsrpc_readds(vnode_t vp, struct uio *uiop, nfsv4state
nd->nd_mrep = NULL;
if (vers == 0 || vers == NFS_VER4) {
nfscl_reqstart(nd, NFSPROC_READDS, nmp, fhp->nfh_fh,
- fhp->nfh_len, NULL, &dsp->nfsclds_sess, vers, minorvers);
+ fhp->nfh_len, NULL, &dsp->nfsclds_sess, vers, minorvers,
+ false);
vers = NFS_VER4;
NFSCL_DEBUG(4, "nfsrpc_readds: vers4 minvers=%d\n", minorvers);
if (flex != 0)
@@ -6309,7 +6314,8 @@ nfsrpc_readds(vnode_t vp, struct uio *uiop, nfsv4state
nfsm_stateidtom(nd, stateidp, NFSSTATEID_PUTSEQIDZERO);
} else {
nfscl_reqstart(nd, NFSPROC_READ, nmp, fhp->nfh_fh,
- fhp->nfh_len, NULL, &dsp->nfsclds_sess, vers, minorvers);
+ fhp->nfh_len, NULL, &dsp->nfsclds_sess, vers, minorvers,
+ false);
NFSCL_DEBUG(4, "nfsrpc_readds: vers3\n");
}
NFSM_BUILD(tl, uint32_t *, NFSX_UNSIGNED * 3);
@@ -6374,7 +6380,8 @@ nfsrpc_writeds(vnode_t vp, struct uio *uiop, int *iomo
nd->nd_mrep = NULL;
if (vers == 0 || vers == NFS_VER4) {
nfscl_reqstart(nd, NFSPROC_WRITEDS, nmp, fhp->nfh_fh,
- fhp->nfh_len, NULL, &dsp->nfsclds_sess, vers, minorvers);
+ fhp->nfh_len, NULL, &dsp->nfsclds_sess, vers, minorvers,
+ false);
NFSCL_DEBUG(4, "nfsrpc_writeds: vers4 minvers=%d\n", minorvers);
vers = NFS_VER4;
if (flex != 0)
@@ -6384,7 +6391,8 @@ nfsrpc_writeds(vnode_t vp, struct uio *uiop, int *iomo
NFSM_BUILD(tl, uint32_t *, NFSX_HYPER + 2 * NFSX_UNSIGNED);
} else {
nfscl_reqstart(nd, NFSPROC_WRITE, nmp, fhp->nfh_fh,
- fhp->nfh_len, NULL, &dsp->nfsclds_sess, vers, minorvers);
+ fhp->nfh_len, NULL, &dsp->nfsclds_sess, vers, minorvers,
+ false);
NFSCL_DEBUG(4, "nfsrpc_writeds: vers3\n");
NFSM_BUILD(tl, uint32_t *, NFSX_HYPER + 3 * NFSX_UNSIGNED);
}
@@ -6503,7 +6511,8 @@ nfsrpc_writedsmir(vnode_t vp, int *iomode, int *must_c
nd->nd_mrep = NULL;
if (vers == 0 || vers == NFS_VER4) {
nfscl_reqstart(nd, NFSPROC_WRITEDS, nmp, fhp->nfh_fh,
- fhp->nfh_len, NULL, &dsp->nfsclds_sess, vers, minorvers);
+ fhp->nfh_len, NULL, &dsp->nfsclds_sess, vers, minorvers,
+ false);
vers = NFS_VER4;
NFSCL_DEBUG(4, "nfsrpc_writedsmir: vers4 minvers=%d\n",
minorvers);
@@ -6511,7 +6520,8 @@ nfsrpc_writedsmir(vnode_t vp, int *iomode, int *must_c
NFSM_BUILD(tl, uint32_t *, NFSX_HYPER + 2 * NFSX_UNSIGNED);
} else {
nfscl_reqstart(nd, NFSPROC_WRITE, nmp, fhp->nfh_fh,
- fhp->nfh_len, NULL, &dsp->nfsclds_sess, vers, minorvers);
+ fhp->nfh_len, NULL, &dsp->nfsclds_sess, vers, minorvers,
+ false);
NFSCL_DEBUG(4, "nfsrpc_writedsmir: vers3\n");
NFSM_BUILD(tl, uint32_t *, NFSX_HYPER + 3 * NFSX_UNSIGNED);
}
@@ -6732,11 +6742,13 @@ nfsrpc_commitds(vnode_t vp, uint64_t offset, int cnt,
nd->nd_mrep = NULL;
if (vers == 0 || vers == NFS_VER4) {
nfscl_reqstart(nd, NFSPROC_COMMITDS, nmp, fhp->nfh_fh,
- fhp->nfh_len, NULL, &dsp->nfsclds_sess, vers, minorvers);
+ fhp->nfh_len, NULL, &dsp->nfsclds_sess, vers, minorvers,
+ false);
vers = NFS_VER4;
} else
nfscl_reqstart(nd, NFSPROC_COMMIT, nmp, fhp->nfh_fh,
- fhp->nfh_len, NULL, &dsp->nfsclds_sess, vers, minorvers);
+ fhp->nfh_len, NULL, &dsp->nfsclds_sess, vers, minorvers,
+ false);
NFSCL_DEBUG(4, "nfsrpc_commitds: vers=%d minvers=%d\n", vers,
minorvers);
NFSM_BUILD(tl, uint32_t *, NFSX_HYPER + NFSX_UNSIGNED);
@@ -6889,7 +6901,7 @@ nfsrpc_adviseds(vnode_t vp, uint64_t offset, int cnt,
return (0);
nd->nd_mrep = NULL;
nfscl_reqstart(nd, NFSPROC_IOADVISEDS, nmp, fhp->nfh_fh,
- fhp->nfh_len, NULL, &dsp->nfsclds_sess, vers, minorvers);
+ fhp->nfh_len, NULL, &dsp->nfsclds_sess, vers, minorvers, false);
vers = NFS_VER4;
NFSCL_DEBUG(4, "nfsrpc_adviseds: vers=%d minvers=%d\n", vers,
minorvers);
@@ -7544,7 +7556,7 @@ nfsrpc_openlayoutrpc(struct nfsmount *nmp, vnode_t vp,
*dpp = NULL;
*laystatp = ENXIO;
nfscl_reqstart(nd, NFSPROC_OPENLAYGET, nmp, nfhp, fhlen, NULL, NULL,
- 0, 0);
+ 0, 0, false);
NFSM_BUILD(tl, uint32_t *, 5 * NFSX_UNSIGNED);
*tl++ = txdr_unsigned(op->nfso_own->nfsow_seqid);
*tl++ = txdr_unsigned(mode & NFSV4OPEN_ACCESSBOTH);
Modified: head/sys/fs/nfsserver/nfs_nfsdport.c
==============================================================================
--- head/sys/fs/nfsserver/nfs_nfsdport.c Fri Jun 26 00:58:59 2020 (r362638)
+++ head/sys/fs/nfsserver/nfs_nfsdport.c Fri Jun 26 03:11:54 2020 (r362639)
@@ -4987,7 +4987,7 @@ nfsrv_readdsrpc(fhandle_t *fhp, off_t off, int len, st
st.other[2] = 0x55555555;
st.seqid = 0xffffffff;
nfscl_reqstart(nd, NFSPROC_READDS, nmp, (u_int8_t *)fhp, sizeof(*fhp),
- NULL, NULL, 0, 0);
+ NULL, NULL, 0, 0, false);
nfsm_stateidtom(nd, &st, NFSSTATEID_PUTSTATEID);
NFSM_BUILD(tl, uint32_t *, NFSX_UNSIGNED * 3);
txdr_hyper(off, tl);
@@ -5095,7 +5095,7 @@ nfsrv_writedsdorpc(struct nfsmount *nmp, fhandle_t *fh
nd = malloc(sizeof(*nd), M_TEMP, M_WAITOK | M_ZERO);
nfscl_reqstart(nd, NFSPROC_WRITE, nmp, (u_int8_t *)fhp,
- sizeof(fhandle_t), NULL, NULL, 0, 0);
+ sizeof(fhandle_t), NULL, NULL, 0, 0, false);
/*
* Use a stateid where other is an alternating 01010 pattern and
@@ -5317,7 +5317,7 @@ nfsrv_allocatedsdorpc(struct nfsmount *nmp, fhandle_t
nd = malloc(sizeof(*nd), M_TEMP, M_WAITOK | M_ZERO);
nfscl_reqstart(nd, NFSPROC_ALLOCATE, nmp, (u_int8_t *)fhp,
- sizeof(fhandle_t), NULL, NULL, 0, 0);
+ sizeof(fhandle_t), NULL, NULL, 0, 0, false);
/*
* Use a stateid where other is an alternating 01010 pattern and
@@ -5471,7 +5471,7 @@ nfsrv_setattrdsdorpc(fhandle_t *fhp, struct ucred *cre
st.other[2] = 0x55555555;
st.seqid = 0xffffffff;
nfscl_reqstart(nd, NFSPROC_SETATTR, nmp, (u_int8_t *)fhp, sizeof(*fhp),
- NULL, NULL, 0, 0);
+ NULL, NULL, 0, 0, false);
nfsm_stateidtom(nd, &st, NFSSTATEID_PUTSTATEID);
nfscl_fillsattr(nd, &nap->na_vattr, vp, NFSSATTR_FULL, 0);
@@ -5656,7 +5656,7 @@ nfsrv_setacldsdorpc(fhandle_t *fhp, struct ucred *cred
st.other[2] = 0x55555555;
st.seqid = 0xffffffff;
nfscl_reqstart(nd, NFSPROC_SETACL, nmp, (u_int8_t *)fhp, sizeof(*fhp),
- NULL, NULL, 0, 0);
+ NULL, NULL, 0, 0, false);
nfsm_stateidtom(nd, &st, NFSSTATEID_PUTSTATEID);
NFSZERO_ATTRBIT(&attrbits);
NFSSETBIT_ATTRBIT(&attrbits, NFSATTRBIT_ACL);
@@ -5791,7 +5791,7 @@ nfsrv_getattrdsrpc(fhandle_t *fhp, struct ucred *cred,
NFSD_DEBUG(4, "in nfsrv_getattrdsrpc\n");
nd = malloc(sizeof(*nd), M_TEMP, M_WAITOK | M_ZERO);
nfscl_reqstart(nd, NFSPROC_GETATTR, nmp, (u_int8_t *)fhp,
- sizeof(fhandle_t), NULL, NULL, 0, 0);
+ sizeof(fhandle_t), NULL, NULL, 0, 0, false);
NFSZERO_ATTRBIT(&attrbits);
NFSSETBIT_ATTRBIT(&attrbits, NFSATTRBIT_SIZE);
NFSSETBIT_ATTRBIT(&attrbits, NFSATTRBIT_CHANGE);
@@ -5859,7 +5859,7 @@ nfsrv_seekdsrpc(fhandle_t *fhp, off_t *offp, int conte
st.seqid = 0xffffffff;
nd = malloc(sizeof(*nd), M_TEMP, M_WAITOK | M_ZERO);
nfscl_reqstart(nd, NFSPROC_SEEKDS, nmp, (u_int8_t *)fhp,
- sizeof(fhandle_t), NULL, NULL, 0, 0);
+ sizeof(fhandle_t), NULL, NULL, 0, 0, false);
nfsm_stateidtom(nd, &st, NFSSTATEID_PUTSTATEID);
NFSM_BUILD(tl, uint32_t *, NFSX_HYPER + NFSX_UNSIGNED);
txdr_hyper(*offp, tl); tl += 2;
More information about the svn-src-all
mailing list