diff options
author | Trond Myklebust <trond.myklebust@hammerspace.com> | 2021-07-11 01:07:14 +0300 |
---|---|---|
committer | Trond Myklebust <trond.myklebust@hammerspace.com> | 2021-10-04 03:49:05 +0300 |
commit | ca05cbae2a0468e5d78e9b4605936a8bf5da328b (patch) | |
tree | bd06e45fe70eb94249052670f024a9cec272ca8e /include/linux/nfs_fs.h | |
parent | 9019fb391de02cbff422090768b73afe9f6174df (diff) | |
download | linux-ca05cbae2a0468e5d78e9b4605936a8bf5da328b.tar.xz |
NFS: Fix up nfs_ctx_key_to_expire()
If the cached credential exists but doesn't have any expiration callback
then exit early.
Fix up atomicity issues when replacing the credential with a new one
since the existing code could lead to refcount leaks.
Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>
Diffstat (limited to 'include/linux/nfs_fs.h')
-rw-r--r-- | include/linux/nfs_fs.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/nfs_fs.h b/include/linux/nfs_fs.h index b9a8b925db43..9b75448ce0df 100644 --- a/include/linux/nfs_fs.h +++ b/include/linux/nfs_fs.h @@ -81,7 +81,7 @@ struct nfs_open_context { fl_owner_t flock_owner; struct dentry *dentry; const struct cred *cred; - struct rpc_cred *ll_cred; /* low-level cred - use to check for expiry */ + struct rpc_cred __rcu *ll_cred; /* low-level cred - use to check for expiry */ struct nfs4_state *state; fmode_t mode; |