diff mbox series

[03/24] freevxfs: Remove check of PageError

Message ID 20220527155036.524743-4-willy@infradead.org (mailing list archive)
State New, archived
Headers show
Series Begin removing PageError | expand

Commit Message

Matthew Wilcox May 27, 2022, 3:50 p.m. UTC
If read_mapping_page() encounters an error, it returns an errno, not a
page with PageError set, so this is dead code.

Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org>
---
 fs/freevxfs/vxfs_subr.c | 6 ------
 1 file changed, 6 deletions(-)

Comments

Christoph Hellwig May 28, 2022, 5:48 a.m. UTC | #1
>  		/** if (!PageChecked(pp)) **/
>  			/** vxfs_check_page(pp); **/
> -		if (PageError(pp))
> -			goto fail;

Can you remove this comment out code as well while you're at it?

Otherwise looks good:

Reviewed-by: Christoph Hellwig <hch@lst.de>
diff mbox series

Patch

diff --git a/fs/freevxfs/vxfs_subr.c b/fs/freevxfs/vxfs_subr.c
index 6143ebab940d..041e818c4577 100644
--- a/fs/freevxfs/vxfs_subr.c
+++ b/fs/freevxfs/vxfs_subr.c
@@ -75,15 +75,9 @@  vxfs_get_page(struct address_space *mapping, u_long n)
 		kmap(pp);
 		/** if (!PageChecked(pp)) **/
 			/** vxfs_check_page(pp); **/
-		if (PageError(pp))
-			goto fail;
 	}
 	
 	return (pp);
-		 
-fail:
-	vxfs_put_page(pp);
-	return ERR_PTR(-EIO);
 }
 
 /**