diff options
author | Christoph Hellwig <hch@lst.de> | 2017-05-27 04:16:54 -0400 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2017-06-29 17:49:24 -0400 |
commit | a4058c5bce8aded1a12a59990e84e481a96fb490 (patch) | |
tree | bd088364ec937246e970a70bb207deecdaf69c12 /fs/nfsd/vfs.c | |
parent | 73da852e3831bdc7a38d8d5fba178f35c923b264 (diff) |
nfsd: remove nfsd_vfs_read
Simpler done in the only caller.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs/nfsd/vfs.c')
-rw-r--r-- | fs/nfsd/vfs.c | 17 |
1 files changed, 6 insertions, 11 deletions
diff --git a/fs/nfsd/vfs.c b/fs/nfsd/vfs.c index 37a03c456b38..0d19ab1b9404 100644 --- a/fs/nfsd/vfs.c +++ b/fs/nfsd/vfs.c | |||
@@ -920,16 +920,6 @@ __be32 nfsd_readv(struct file *file, loff_t offset, struct kvec *vec, int vlen, | |||
920 | return nfsd_finish_read(file, count, host_err); | 920 | return nfsd_finish_read(file, count, host_err); |
921 | } | 921 | } |
922 | 922 | ||
923 | static __be32 | ||
924 | nfsd_vfs_read(struct svc_rqst *rqstp, struct file *file, | ||
925 | loff_t offset, struct kvec *vec, int vlen, unsigned long *count) | ||
926 | { | ||
927 | if (file->f_op->splice_read && test_bit(RQ_SPLICE_OK, &rqstp->rq_flags)) | ||
928 | return nfsd_splice_read(rqstp, file, offset, count); | ||
929 | else | ||
930 | return nfsd_readv(file, offset, vec, vlen, count); | ||
931 | } | ||
932 | |||
933 | /* | 923 | /* |
934 | * Gathered writes: If another process is currently writing to the file, | 924 | * Gathered writes: If another process is currently writing to the file, |
935 | * there's a high chance this is another nfsd (triggered by a bulk write | 925 | * there's a high chance this is another nfsd (triggered by a bulk write |
@@ -1041,7 +1031,12 @@ __be32 nfsd_read(struct svc_rqst *rqstp, struct svc_fh *fhp, | |||
1041 | ra = nfsd_init_raparms(file); | 1031 | ra = nfsd_init_raparms(file); |
1042 | 1032 | ||
1043 | trace_read_opened(rqstp, fhp, offset, vlen); | 1033 | trace_read_opened(rqstp, fhp, offset, vlen); |
1044 | err = nfsd_vfs_read(rqstp, file, offset, vec, vlen, count); | 1034 | |
1035 | if (file->f_op->splice_read && test_bit(RQ_SPLICE_OK, &rqstp->rq_flags)) | ||
1036 | err = nfsd_splice_read(rqstp, file, offset, count); | ||
1037 | else | ||
1038 | err = nfsd_readv(file, offset, vec, vlen, count); | ||
1039 | |||
1045 | trace_read_io_done(rqstp, fhp, offset, vlen); | 1040 | trace_read_io_done(rqstp, fhp, offset, vlen); |
1046 | 1041 | ||
1047 | if (ra) | 1042 | if (ra) |