summaryrefslogtreecommitdiffstats
path: root/fs
diff options
context:
space:
mode:
authorTrond Myklebust <trond.myklebust@primarydata.com>2018-03-20 16:43:14 -0400
committerAnna Schumaker <Anna.Schumaker@Netapp.com>2018-04-10 16:06:22 -0400
commit9f7682728728114ed99d8f127f0e1ce3ef9ba857 (patch)
treeeaa2fcf319f8cf953959c5070285bf04f6262c7a /fs
parentf50862423f547f8506d69b6e4fc53be53288244c (diff)
NFS: Move the delegation return down into nfs4_proc_link()
Move the delegation return out of generic code. Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com>
Diffstat (limited to 'fs')
-rw-r--r--fs/nfs/dir.c2
-rw-r--r--fs/nfs/nfs4proc.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/fs/nfs/dir.c b/fs/nfs/dir.c
index 2f3f86726f5b..b4549e54007d 100644
--- a/fs/nfs/dir.c
+++ b/fs/nfs/dir.c
@@ -1932,8 +1932,6 @@ nfs_link(struct dentry *old_dentry, struct inode *dir, struct dentry *dentry)
1932 old_dentry, dentry); 1932 old_dentry, dentry);
1933 1933
1934 trace_nfs_link_enter(inode, dir, dentry); 1934 trace_nfs_link_enter(inode, dir, dentry);
1935 NFS_PROTO(inode)->return_delegation(inode);
1936
1937 d_drop(dentry); 1935 d_drop(dentry);
1938 error = NFS_PROTO(dir)->link(inode, dir, &dentry->d_name); 1936 error = NFS_PROTO(dir)->link(inode, dir, &dentry->d_name);
1939 if (error == 0) { 1937 if (error == 0) {
diff --git a/fs/nfs/nfs4proc.c b/fs/nfs/nfs4proc.c
index 71f2916f93ff..f4216b6b01c9 100644
--- a/fs/nfs/nfs4proc.c
+++ b/fs/nfs/nfs4proc.c
@@ -4318,6 +4318,8 @@ static int _nfs4_proc_link(struct inode *inode, struct inode *dir, const struct
4318 } 4318 }
4319 arg.bitmask = nfs4_bitmask(server, res.label); 4319 arg.bitmask = nfs4_bitmask(server, res.label);
4320 4320
4321 nfs4_inode_return_delegation(inode);
4322
4321 status = nfs4_call_sync(server->client, server, &msg, &arg.seq_args, &res.seq_res, 1); 4323 status = nfs4_call_sync(server->client, server, &msg, &arg.seq_args, &res.seq_res, 1);
4322 if (!status) { 4324 if (!status) {
4323 update_changeattr(dir, &res.cinfo, res.fattr->time_start); 4325 update_changeattr(dir, &res.cinfo, res.fattr->time_start);