Skip to contentSkip to conversation

ceph: don't SetPageError on readpage errors

PATCH In review Jeff Layton 2 participants 2 messages Oct 6, 2020 Ceph client

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ceph: don't SetPageError on readpage errors

PageError really only has meaning within a particular subsystem. Nothing looks at this bit in the core kernel code, and ceph itself doesn't care about it. Don't bother setting the PageError bit on error.

Cc Matthew Wilcox <[email protected]>
---
 fs/ceph/addr.c | 1 -
 1 file changed, 1 deletion(-)
fs/ceph/addr.c +0 -1
index 97827f68a3e7..137c0a5a2a0d 100644
@@ -241,7 +241,6 @@ static int ceph_do_readpage(struct file *filp, struct page *page)
 	if (err == -ENOENT)
 		err = 0;
 	if (err < 0) {
-		SetPageError(page);
 		ceph_fscache_readpage_cancel(inode, page);
 		if (err == -EBLOCKLISTED)
 			fsc->blocklisted = true;
Signature · 1 line
2.26.2
Reviewed-by on v1 1/1
#1 lore raw
Quoted 3 lines · Jeff Layton

PageError really only has meaning within a particular subsystem. Nothing looks at this bit in the core kernel code, and ceph itself doesn't care about it. Don't bother setting the PageError bit on error.

I wondered if fscache might be interested, but it seems like it doesn't particularly care. It's still interested in PageError for backing store pages, but not for the filesystem being cached.

Quoted 21 lines
Cc Matthew Wilcox <[email protected]>
---
 fs/ceph/addr.c | 1 -
 1 file changed, 1 deletion(-)
fs/ceph/addr.c +0 -1
index 97827f68a3e7..137c0a5a2a0d 100644
@@ -241,7 +241,6 @@ static int ceph_do_readpage(struct file *filp, struct page *page)
 	if (err == -ENOENT)
 		err = 0;
 	if (err < 0) {
-		SetPageError(page);
 		ceph_fscache_readpage_cancel(inode, page);
 		if (err == -EBLOCKLISTED)
 			fsc->blocklisted = true;
Signature · 1 line
2.26.2