From: Andy Adamson Date: Thu, 11 Apr 2013 13:28:45 +0000 (-0400) Subject: NFSv4 release the sequence id in the return on close case X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=b9536ad52152ff440231dcc2dd9cfa644f5413c9;p=openwrt%2Fstaging%2Fblogic.git NFSv4 release the sequence id in the return on close case Otherwise we deadlock if state recovery is initiated while we sleep. Signed-off-by: Andy Adamson Signed-off-by: Trond Myklebust --- diff --git a/fs/nfs/nfs4proc.c b/fs/nfs/nfs4proc.c index 264ddb16255f..83197fb60d5f 100644 --- a/fs/nfs/nfs4proc.c +++ b/fs/nfs/nfs4proc.c @@ -2275,8 +2275,10 @@ static void nfs4_close_prepare(struct rpc_task *task, void *data) if (calldata->arg.fmode == 0) { task->tk_msg.rpc_proc = &nfs4_procedures[NFSPROC4_CLNT_CLOSE]; if (calldata->roc && - pnfs_roc_drain(inode, &calldata->roc_barrier, task)) + pnfs_roc_drain(inode, &calldata->roc_barrier, task)) { + nfs_release_seqid(calldata->arg.seqid); goto out_wait; + } } nfs_fattr_init(calldata->res.fattr);