Skip to content

Commit

Permalink
nfsd: remove some unnecessary dropit handling
Browse files Browse the repository at this point in the history
We no longer need a few of these special cases.

Signed-off-by: J. Bruce Fields <bfields@redhat.com>
  • Loading branch information
J. Bruce Fields committed Jan 4, 2011
1 parent 062304a commit da165dd
Show file tree
Hide file tree
Showing 4 changed files with 0 additions and 12 deletions.
4 changes: 0 additions & 4 deletions fs/nfsd/nfs4proc.c
Original file line number Diff line number Diff line change
Expand Up @@ -1156,10 +1156,6 @@ nfsd4_proc_compound(struct svc_rqst *rqstp,

nfsd4_increment_op_stats(op->opnum);
}
if (!rqstp->rq_usedeferral && status == nfserr_dropit) {
dprintk("%s Dropit - send NFS4ERR_DELAY\n", __func__);
status = nfserr_jukebox;
}

resp->cstate.status = status;
fh_put(&resp->cstate.current_fh);
Expand Down
2 changes: 0 additions & 2 deletions fs/nfsd/nfs4state.c
Original file line number Diff line number Diff line change
Expand Up @@ -2509,8 +2509,6 @@ static __be32 nfs4_get_vfs_file(struct svc_rqst *rqstp, struct nfs4_file
if (!fp->fi_fds[oflag]) {
status = nfsd_open(rqstp, cur_fh, S_IFREG, access,
&fp->fi_fds[oflag]);
if (status == nfserr_dropit)
status = nfserr_jukebox;
if (status)
return status;
}
Expand Down
2 changes: 0 additions & 2 deletions fs/nfsd/nfs4xdr.c
Original file line number Diff line number Diff line change
Expand Up @@ -2328,8 +2328,6 @@ nfsd4_encode_dirent(void *ccdv, const char *name, int namlen,
case nfserr_resource:
nfserr = nfserr_toosmall;
goto fail;
case nfserr_dropit:
goto fail;
case nfserr_noent:
goto skip_entry;
default:
Expand Down
4 changes: 0 additions & 4 deletions fs/nfsd/vfs.c
Original file line number Diff line number Diff line change
Expand Up @@ -380,8 +380,6 @@ nfsd_setattr(struct svc_rqst *rqstp, struct svc_fh *fhp, struct iattr *iap,
* we need to break all leases.
*/
host_err = break_lease(inode, O_WRONLY | O_NONBLOCK);
if (host_err == -EWOULDBLOCK)
host_err = -ETIMEDOUT;
if (host_err) /* ENOMEM or EWOULDBLOCK */
goto out_nfserr;

Expand Down Expand Up @@ -752,8 +750,6 @@ nfsd_open(struct svc_rqst *rqstp, struct svc_fh *fhp, int type,
*/
if (!(access & NFSD_MAY_NOT_BREAK_LEASE))
host_err = break_lease(inode, O_NONBLOCK | ((access & NFSD_MAY_WRITE) ? O_WRONLY : 0));
if (host_err == -EWOULDBLOCK)
host_err = -ETIMEDOUT;
if (host_err) /* NOMEM or WOULDBLOCK */
goto out_nfserr;

Expand Down

0 comments on commit da165dd

Please sign in to comment.