Skip to content

Commit 5326de9

Browse files
author
Trond Myklebust
committed
NFSv4.x: Drop the slot if nfs4_delegreturn_prepare waits for layoutreturn
If nfs4_delegreturn_prepare needs to wait for a layoutreturn to complete then make sure we drop the sequence slot if we hold it. Fixes: 1c5bd76 ("pNFS: Enable layoutreturn operation for return-on-close") Signed-off-by: Trond Myklebust <[email protected]>
1 parent 5c44154 commit 5326de9

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

fs/nfs/nfs4proc.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6256,8 +6256,10 @@ static void nfs4_delegreturn_prepare(struct rpc_task *task, void *data)
62566256

62576257
d_data = (struct nfs4_delegreturndata *)data;
62586258

6259-
if (!d_data->lr.roc && nfs4_wait_on_layoutreturn(d_data->inode, task))
6259+
if (!d_data->lr.roc && nfs4_wait_on_layoutreturn(d_data->inode, task)) {
6260+
nfs4_sequence_done(task, &d_data->res.seq_res);
62606261
return;
6262+
}
62616263

62626264
lo = d_data->args.lr_args ? d_data->args.lr_args->layout : NULL;
62636265
if (lo && !pnfs_layout_is_valid(lo)) {

0 commit comments

Comments
 (0)