FreeBSD Bugzilla – Attachment 223584 Details for
Bug 254560
NFSv4.1 server broken when mounted by Linux using nconnects
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
fix NFSv4.1 server so that it does not bind a new conn to backchannel
cbnull.patch (text/plain), 2.29 KB, created by
Rick Macklem
on 2021-03-25 22:09:43 UTC
(
hide
)
Description:
fix NFSv4.1 server so that it does not bind a new conn to backchannel
Filename:
MIME Type:
Creator:
Rick Macklem
Created:
2021-03-25 22:09:43 UTC
Size:
2.29 KB
patch
obsolete
>--- sys/fs/nfsserver/nfs_nfsdstate.c.cbnull 2021-03-23 12:01:54.986956000 -0700 >+++ sys/fs/nfsserver/nfs_nfsdstate.c 2021-03-23 13:09:01.236338000 -0700 >@@ -6209,7 +6209,6 @@ nfsrv_checksequence(struct nfsrv_descript *nd, uint32_ > struct nfsdsession *sep; > struct nfssessionhash *shp; > int error; >- SVCXPRT *savxprt; > > shp = NFSSESSIONHASH(nd->nd_sessionid); > NFSLOCKSESSION(shp); >@@ -6235,36 +6234,11 @@ nfsrv_checksequence(struct nfsrv_descript *nd, uint32_ > nd->nd_maxreq = sep->sess_maxreq; > nd->nd_maxresp = sep->sess_maxresp; > >- /* >- * If this session handles the backchannel, save the nd_xprt for this >- * RPC, since this is the one being used. >- * RFC-5661 specifies that the fore channel will be implicitly >- * bound by a Sequence operation. However, since some NFSv4.1 clients >- * erroneously assumed that the back channel would be implicitly >- * bound as well, do the implicit binding unless a >- * BindConnectiontoSession has already been done on the session. >- */ >- savxprt = NULL; >- if (sep->sess_clp->lc_req.nr_client != NULL && >- sep->sess_cbsess.nfsess_xprt != nd->nd_xprt && >- (sep->sess_crflags & NFSV4CRSESS_CONNBACKCHAN) != 0 && >- (sep->sess_clp->lc_flags & LCL_DONEBINDCONN) == 0) { >- NFSD_DEBUG(2, >- "nfsrv_checksequence: implicit back channel bind\n"); >- savxprt = sep->sess_cbsess.nfsess_xprt; >- SVC_ACQUIRE(nd->nd_xprt); >- nd->nd_xprt->xp_p2 = >- sep->sess_clp->lc_req.nr_client->cl_private; >- nd->nd_xprt->xp_idletimeout = 0; /* Disable timeout. */ >- sep->sess_cbsess.nfsess_xprt = nd->nd_xprt; >- } >- > *sflagsp = 0; >- if (sep->sess_clp->lc_req.nr_client == NULL) >+ if (sep->sess_clp->lc_req.nr_client == NULL || >+ (sep->sess_clp->lc_flags & LCL_CBDOWN) != 0) > *sflagsp |= NFSV4SEQ_CBPATHDOWN; > NFSUNLOCKSESSION(shp); >- if (savxprt != NULL) >- SVC_RELEASE(savxprt); > if (error == NFSERR_EXPIRED) { > *sflagsp |= NFSV4SEQ_EXPIREDALLSTATEREVOKED; > error = 0; >@@ -6464,7 +6438,8 @@ nfsrv_bindconnsess(struct nfsrv_descript *nd, uint8_t > nd->nd_xprt->xp_idletimeout = 0; > sep->sess_cbsess.nfsess_xprt = nd->nd_xprt; > sep->sess_crflags |= NFSV4CRSESS_CONNBACKCHAN; >- clp->lc_flags |= LCL_DONEBINDCONN; >+ clp->lc_flags |= LCL_DONEBINDCONN | >+ LCL_NEEDSCBNULL; > if (*foreaftp == NFSCDFS4_BACK) > *foreaftp = NFSCDFS4_BACK; > else
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 254560
: 223584 |
223813
|
223814