NFSv4: nfs4_locku_done must release the sequence id
authorTrond Myklebust <Trond.Myklebust@netapp.com>
Mon, 29 Oct 2012 22:53:23 +0000 (18:53 -0400)
committerBen Hutchings <ben@decadent.org.uk>
Fri, 16 Nov 2012 16:47:04 +0000 (16:47 +0000)
commit 2b1bc308f492589f7d49012ed24561534ea2be8c upstream.

If the state recovery machinery is triggered by the call to
nfs4_async_handle_error() then we can deadlock.

Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
fs/nfs/nfs4proc.c

index 4f07b56..864b831 100644 (file)
@@ -4150,6 +4150,7 @@ static void nfs4_locku_done(struct rpc_task *task, void *data)
                        if (nfs4_async_handle_error(task, calldata->server, NULL) == -EAGAIN)
                                rpc_restart_call_prepare(task);
        }
+       nfs_release_seqid(calldata->arg.seqid);
 }
 
 static void nfs4_locku_prepare(struct rpc_task *task, void *data)