提交 d08d32e6 编写于 作者: J J. Bruce Fields

nfsd4: return delegation immediately if lease fails

This case shouldn't happen--the administrator shouldn't really allow
other applications access to the export until clients have had the
chance to reclaim their state--but if it does then we should set the
"return this lease immediately" bit on the reply.  That still leaves
some small races, but it's the best the protocol allows us to do in the
case a lease is ripped out from under us....
Signed-off-by: NJ. Bruce Fields <bfields@redhat.com>
上级 0a262ffb
...@@ -3143,8 +3143,10 @@ nfs4_open_delegation(struct net *net, struct svc_fh *fh, ...@@ -3143,8 +3143,10 @@ nfs4_open_delegation(struct net *net, struct svc_fh *fh,
out_no_deleg: out_no_deleg:
open->op_delegate_type = NFS4_OPEN_DELEGATE_NONE; open->op_delegate_type = NFS4_OPEN_DELEGATE_NONE;
if (open->op_claim_type == NFS4_OPEN_CLAIM_PREVIOUS && if (open->op_claim_type == NFS4_OPEN_CLAIM_PREVIOUS &&
open->op_delegate_type != NFS4_OPEN_DELEGATE_NONE) open->op_delegate_type != NFS4_OPEN_DELEGATE_NONE) {
dprintk("NFSD: WARNING: refusing delegation reclaim\n"); dprintk("NFSD: WARNING: refusing delegation reclaim\n");
open->op_recall = 1;
}
/* 4.1 client asking for a delegation? */ /* 4.1 client asking for a delegation? */
if (open->op_deleg_want) if (open->op_deleg_want)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册