NFSv4: Fix sillyrename to return the delegation when appropriate

Ensure that we pass down the inode of the file being deleted so
that we can return any delegation being held.

Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>
This commit is contained in:
Trond Myklebust
2018-05-30 16:11:52 -04:00
parent 991eedb137
commit ed7e9ad090
5 changed files with 15 additions and 10 deletions

View File

@@ -4260,11 +4260,12 @@ static int nfs4_proc_rmdir(struct inode *dir, const struct qstr *name)
return err;
}
static void nfs4_proc_unlink_setup(struct rpc_message *msg, struct dentry *dentry)
static void nfs4_proc_unlink_setup(struct rpc_message *msg,
struct dentry *dentry,
struct inode *inode)
{
struct nfs_removeargs *args = msg->rpc_argp;
struct nfs_removeres *res = msg->rpc_resp;
struct inode *inode = d_inode(dentry);
res->server = NFS_SB(dentry->d_sb);
msg->rpc_proc = &nfs4_procedures[NFSPROC4_CLNT_REMOVE];