NFS: Move the delegation return down into nfs4_proc_remove()
Move the delegation return out of generic code and down into the NFSv4 specific unlink code. Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com>
This commit is contained in:

committed by
Anna Schumaker

parent
9f76827287
commit
912678dbc5
@@ -1798,12 +1798,11 @@ static int nfs_safe_remove(struct dentry *dentry)
|
||||
|
||||
trace_nfs_remove_enter(dir, dentry);
|
||||
if (inode != NULL) {
|
||||
NFS_PROTO(inode)->return_delegation(inode);
|
||||
error = NFS_PROTO(dir)->remove(dir, &dentry->d_name);
|
||||
error = NFS_PROTO(dir)->remove(dir, dentry);
|
||||
if (error == 0)
|
||||
nfs_drop_nlink(inode);
|
||||
} else
|
||||
error = NFS_PROTO(dir)->remove(dir, &dentry->d_name);
|
||||
error = NFS_PROTO(dir)->remove(dir, dentry);
|
||||
if (error == -ENOENT)
|
||||
nfs_dentry_handle_enoent(dentry);
|
||||
trace_nfs_remove_exit(dir, dentry, error);
|
||||
|
Reference in New Issue
Block a user