mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-01-26 18:43:33 -05:00
ceph fscache: Uncaching no data page from fscache in readpage()
Currently, if one new page allocated into fscache in readpage(), however, with no data read into due to error encountered during reading from OSDs, the slot in fscache is not uncached. This patch fixes this. Signed-off-by: Li Wang <liwang@ubuntukylin.com> Reviewed-by: Milosz Tanski <milosz@adfin.com>
This commit is contained in:
parent
3f42bc4bea
commit
183028052b
1 changed files with 1 additions and 0 deletions
|
@ -209,6 +209,7 @@ static int readpage_nounlock(struct file *filp, struct page *page)
|
|||
err = 0;
|
||||
if (err < 0) {
|
||||
SetPageError(page);
|
||||
ceph_fscache_readpage_cancel(inode, page);
|
||||
goto out;
|
||||
} else {
|
||||
if (err < PAGE_CACHE_SIZE) {
|
||||
|
|
Loading…
Add table
Reference in a new issue