For the file that was once cached into PCC but detached from PCC
later, it should fall back into the normal I/O path to direct I/Os
to Lustre OSTs for splice read, not just return zero.
Signed-off-by: Qian Yingjin <qian@ddn.com>
Change-Id: Iff3449069a0a12ac56b58618e474749361c31bb7
Reviewed-on: https://review.whamcloud.com/40396
Reviewed-by: James Simmons <jsimmons@infradead.org>
Tested-by: jenkins <devops@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
RETURN(default_file_splice_read(in_file, ppos, pipe,
RETURN(default_file_splice_read(in_file, ppos, pipe,
pcc_io_init(inode, PIT_SPLICE_READ, &cached);
if (!cached)
pcc_io_init(inode, PIT_SPLICE_READ, &cached);
if (!cached)
+ RETURN(default_file_splice_read(in_file, ppos, pipe,
+ count, flags));
result = default_file_splice_read(pcc_file, ppos, pipe, count, flags);
result = default_file_splice_read(pcc_file, ppos, pipe, count, flags);