Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge tag 'nfs-for-4.10-4' of git://git.linux-nfs.org/projects/trondmy/linux-nfs

Pull NFS client bugfixes from Trond Myklebust:
"Stable patches:
- NFSv4.1: Fix a deadlock in layoutget
- NFSv4 must not bump sequence ids on NFS4ERR_MOVED errors
- NFSv4 Fix a regression with OPEN EXCLUSIVE4 mode
- Fix a memory leak when removing the SUNRPC module

Bugfixes:
- Fix a reference leak in _pnfs_return_layout"

* tag 'nfs-for-4.10-4' of git://git.linux-nfs.org/projects/trondmy/linux-nfs:
pNFS: Fix a reference leak in _pnfs_return_layout
nfs: Fix "Don't increment lock sequence ID after NFS4ERR_MOVED"
SUNRPC: cleanup ida information when removing sunrpc module
NFSv4.0: always send mode in SETATTR after EXCLUSIVE4
nfs: Don't increment lock sequence ID after NFS4ERR_MOVED
NFSv4.1: Fix a deadlock in layoutget

+14 -3
+3 -1
fs/nfs/nfs4proc.c
··· 2700 2700 sattr->ia_valid |= ATTR_MTIME; 2701 2701 2702 2702 /* Except MODE, it seems harmless of setting twice. */ 2703 - if ((attrset[1] & FATTR4_WORD1_MODE)) 2703 + if (opendata->o_arg.createmode != NFS4_CREATE_EXCLUSIVE && 2704 + attrset[1] & FATTR4_WORD1_MODE) 2704 2705 sattr->ia_valid &= ~ATTR_MODE; 2705 2706 2706 2707 if (attrset[2] & FATTR4_WORD2_SECURITY_LABEL) ··· 8491 8490 goto out; 8492 8491 } 8493 8492 8493 + nfs4_sequence_free_slot(&lgp->res.seq_res); 8494 8494 err = nfs4_handle_exception(server, nfs4err, exception); 8495 8495 if (!status) { 8496 8496 if (exception->retry)
+1
fs/nfs/nfs4state.c
··· 1091 1091 case -NFS4ERR_BADXDR: 1092 1092 case -NFS4ERR_RESOURCE: 1093 1093 case -NFS4ERR_NOFILEHANDLE: 1094 + case -NFS4ERR_MOVED: 1094 1095 /* Non-seqid mutating errors */ 1095 1096 return; 1096 1097 };
+1 -1
fs/nfs/pnfs.c
··· 1200 1200 1201 1201 send = pnfs_prepare_layoutreturn(lo, &stateid, NULL); 1202 1202 spin_unlock(&ino->i_lock); 1203 - pnfs_free_lseg_list(&tmp_list); 1204 1203 if (send) 1205 1204 status = pnfs_send_layoutreturn(lo, &stateid, IOMODE_ANY, true); 1206 1205 out_put_layout_hdr: 1206 + pnfs_free_lseg_list(&tmp_list); 1207 1207 pnfs_put_layout_hdr(lo); 1208 1208 out: 1209 1209 dprintk("<-- %s status: %d\n", __func__, status);
+2 -1
include/linux/nfs4.h
··· 282 282 283 283 static inline bool seqid_mutating_err(u32 err) 284 284 { 285 - /* rfc 3530 section 8.1.5: */ 285 + /* See RFC 7530, section 9.1.7 */ 286 286 switch (err) { 287 287 case NFS4ERR_STALE_CLIENTID: 288 288 case NFS4ERR_STALE_STATEID: ··· 291 291 case NFS4ERR_BADXDR: 292 292 case NFS4ERR_RESOURCE: 293 293 case NFS4ERR_NOFILEHANDLE: 294 + case NFS4ERR_MOVED: 294 295 return false; 295 296 }; 296 297 return true;
+1
include/linux/sunrpc/clnt.h
··· 216 216 void rpc_clnt_xprt_switch_add_xprt(struct rpc_clnt *, struct rpc_xprt *); 217 217 bool rpc_clnt_xprt_switch_has_addr(struct rpc_clnt *clnt, 218 218 const struct sockaddr *sap); 219 + void rpc_cleanup_clids(void); 219 220 #endif /* __KERNEL__ */ 220 221 #endif /* _LINUX_SUNRPC_CLNT_H */
+5
net/sunrpc/clnt.c
··· 336 336 337 337 static DEFINE_IDA(rpc_clids); 338 338 339 + void rpc_cleanup_clids(void) 340 + { 341 + ida_destroy(&rpc_clids); 342 + } 343 + 339 344 static int rpc_alloc_clid(struct rpc_clnt *clnt) 340 345 { 341 346 int clid;
+1
net/sunrpc/sunrpc_syms.c
··· 119 119 static void __exit 120 120 cleanup_sunrpc(void) 121 121 { 122 + rpc_cleanup_clids(); 122 123 rpcauth_remove_module(); 123 124 cleanup_socket_xprt(); 124 125 svc_cleanup_xprt_sock();