aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoryangerkun <[email protected]>2020-02-26 12:10:02 +0800
committerTheodore Ts'o <[email protected]>2020-04-15 23:58:48 -0400
commitc2a559bc0e7ed5a715ad6b947025b33cb7c05ea7 (patch)
tree86e8cd9ae771bbde609d9a4fe5fd474dfb86c102
parent00086336a8d96a04aa960f912287692a258f6cf5 (diff)
ext4: use matching invalidatepage in ext4_writepage
Run generic/388 with journal data mode sometimes may trigger the warning in ext4_invalidatepage. Actually, we should use the matching invalidatepage in ext4_writepage. Signed-off-by: yangerkun <[email protected]> Signed-off-by: Theodore Ts'o <[email protected]> Reviewed-by: Ritesh Harjani <[email protected]> Reviewed-by: Jan Kara <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Theodore Ts'o <[email protected]>
-rw-r--r--fs/ext4/inode.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/ext4/inode.c b/fs/ext4/inode.c
index e416096fc081..68f6c0af8e5d 100644
--- a/fs/ext4/inode.c
+++ b/fs/ext4/inode.c
@@ -1973,7 +1973,7 @@ static int ext4_writepage(struct page *page,
bool keep_towrite = false;
if (unlikely(ext4_forced_shutdown(EXT4_SB(inode->i_sb)))) {
- ext4_invalidatepage(page, 0, PAGE_SIZE);
+ inode->i_mapping->a_ops->invalidatepage(page, 0, PAGE_SIZE);
unlock_page(page);
return -EIO;
}