mirror of https://gitee.com/openkylin/linux.git
Miscellaneous nfsd bugfixes, one for a 4.10 regression, three for older
bugs. -----BEGIN PGP SIGNATURE----- iQIcBAABAgAGBQJYfOk6AAoJECebzXlCjuG+Lj4QALaLKRRbIdrz6nmg7gUmpTWc CdW8NMbzwSCXmYoivsTHBlhXZKsi5vVjnFXMCM/P85ddmipXdcTFCDLmmNoKUQ0M jODlLX90ctaZKCDBVSaH4htAz2gkFv7z5IllX0YDQqHyiuzh/9KoV+AFCgPZPTpL O1XRmfWz+yJDydz4hb3i5f2JvMk9P/tCXLnheuxxTIMSl2/fIfgF81eWwDpFqcA2 27+PyWWjZehVnZ77ca/mWJj2n0+gBINiKafcfF39NK/Hv2q4aauB3k7c4blecc9Q m/IT3mKifvHvdNCmvHD5s74h4OikEGYpqaSjonMptZnWgfM4/gtF7yTiQjsOMDx/ w6W/tfHlGrvegpzhjaIaoZZ50EZp7xwGNNZYgH4J44kytYpolrhsOR6NqCLTqpej xG2Kd89ZtnAgc/7T7ET/1PqpZ8f9M9pyV3E8s36OvF4AYQUNrfzbWSTQcZy3WGBP YuoUCzacIbNbGgu4m6Zx5l/vKW5yn45xbUMp7T9S4WoxYMx6a5vViU0NiF7KsQDu pcDT92DZ57KJFtCw7Ig08ILKsSXmNApH5/4mIrkX3quZuH4j2XapEJ9u//fmfZBd Q+Sgv8RXcGELUJIg9yfmoWgPDA/oYslc7ynBV0lXLNgBuod//dGSlZ+6KfFFJYr8 XVOxwPTiiBIlc9lvB9eA =tb4L -----END PGP SIGNATURE----- Merge tag 'nfsd-4.10-1' of git://linux-nfs.org/~bfields/linux Pull nfsd fixes from Bruce Fields: "Miscellaneous nfsd bugfixes, one for a 4.10 regression, three for older bugs" * tag 'nfsd-4.10-1' of git://linux-nfs.org/~bfields/linux: svcrdma: avoid duplicate dma unmapping during error recovery sunrpc: don't call sleeping functions from the notifier block callbacks svcrpc: don't leak contexts on PROC_DESTROY nfsd: fix supported attributes for acl & labels
This commit is contained in:
commit
2eabb8b8d6
|
@ -2440,7 +2440,9 @@ nfsd4_encode_fattr(struct xdr_stream *xdr, struct svc_fh *fhp,
|
|||
p++; /* to be backfilled later */
|
||||
|
||||
if (bmval0 & FATTR4_WORD0_SUPPORTED_ATTRS) {
|
||||
u32 *supp = nfsd_suppattrs[minorversion];
|
||||
u32 supp[3];
|
||||
|
||||
memcpy(supp, nfsd_suppattrs[minorversion], sizeof(supp));
|
||||
|
||||
if (!IS_POSIXACL(dentry->d_inode))
|
||||
supp[0] &= ~FATTR4_WORD0_ACL;
|
||||
|
|
|
@ -66,6 +66,7 @@ struct svc_xprt {
|
|||
#define XPT_LISTENER 10 /* listening endpoint */
|
||||
#define XPT_CACHE_AUTH 11 /* cache auth info */
|
||||
#define XPT_LOCAL 12 /* connection from loopback interface */
|
||||
#define XPT_KILL_TEMP 13 /* call xpo_kill_temp_xprt before closing */
|
||||
|
||||
struct svc_serv *xpt_server; /* service for transport */
|
||||
atomic_t xpt_reserved; /* space on outq that is rsvd */
|
||||
|
|
|
@ -1489,7 +1489,7 @@ svcauth_gss_accept(struct svc_rqst *rqstp, __be32 *authp)
|
|||
case RPC_GSS_PROC_DESTROY:
|
||||
if (gss_write_verf(rqstp, rsci->mechctx, gc->gc_seq))
|
||||
goto auth_err;
|
||||
rsci->h.expiry_time = get_seconds();
|
||||
rsci->h.expiry_time = seconds_since_boot();
|
||||
set_bit(CACHE_NEGATIVE, &rsci->h.flags);
|
||||
if (resv->iov_len + 4 > PAGE_SIZE)
|
||||
goto drop;
|
||||
|
|
|
@ -799,6 +799,8 @@ static int svc_handle_xprt(struct svc_rqst *rqstp, struct svc_xprt *xprt)
|
|||
|
||||
if (test_bit(XPT_CLOSE, &xprt->xpt_flags)) {
|
||||
dprintk("svc_recv: found XPT_CLOSE\n");
|
||||
if (test_and_clear_bit(XPT_KILL_TEMP, &xprt->xpt_flags))
|
||||
xprt->xpt_ops->xpo_kill_temp_xprt(xprt);
|
||||
svc_delete_xprt(xprt);
|
||||
/* Leave XPT_BUSY set on the dead xprt: */
|
||||
goto out;
|
||||
|
@ -1020,9 +1022,11 @@ void svc_age_temp_xprts_now(struct svc_serv *serv, struct sockaddr *server_addr)
|
|||
le = to_be_closed.next;
|
||||
list_del_init(le);
|
||||
xprt = list_entry(le, struct svc_xprt, xpt_list);
|
||||
dprintk("svc_age_temp_xprts_now: closing %p\n", xprt);
|
||||
xprt->xpt_ops->xpo_kill_temp_xprt(xprt);
|
||||
svc_close_xprt(xprt);
|
||||
set_bit(XPT_CLOSE, &xprt->xpt_flags);
|
||||
set_bit(XPT_KILL_TEMP, &xprt->xpt_flags);
|
||||
dprintk("svc_age_temp_xprts_now: queuing xprt %p for closing\n",
|
||||
xprt);
|
||||
svc_xprt_enqueue(xprt);
|
||||
}
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(svc_age_temp_xprts_now);
|
||||
|
|
|
@ -347,8 +347,6 @@ int rdma_read_chunk_frmr(struct svcxprt_rdma *xprt,
|
|||
atomic_inc(&rdma_stat_read);
|
||||
return ret;
|
||||
err:
|
||||
ib_dma_unmap_sg(xprt->sc_cm_id->device,
|
||||
frmr->sg, frmr->sg_nents, frmr->direction);
|
||||
svc_rdma_put_context(ctxt, 0);
|
||||
svc_rdma_put_frmr(xprt, frmr);
|
||||
return ret;
|
||||
|
|
Loading…
Reference in New Issue