diff --git a/fs/iomap/buffered-io.c b/fs/iomap/buffered-io.c index 87a4f5a2ded0..1f0bfe0b8bae 100644 --- a/fs/iomap/buffered-io.c +++ b/fs/iomap/buffered-io.c @@ -1350,7 +1350,6 @@ iomap_writepage_map(struct iomap_writepage_ctx *wpc, if (wpc->ops->discard_page) wpc->ops->discard_page(page, file_offset); if (!count) { - ClearPageUptodate(page); unlock_page(page); goto done; } diff --git a/fs/xfs/xfs_aops.c b/fs/xfs/xfs_aops.c index c8c15c3c3147..56a5bd7ad8c4 100644 --- a/fs/xfs/xfs_aops.c +++ b/fs/xfs/xfs_aops.c @@ -450,7 +450,7 @@ xfs_discard_page( int error; if (xfs_is_shutdown(mp)) - goto out_invalidate; + return; xfs_alert_ratelimited(mp, "page discard on page "PTR_FMT", inode 0x%llx, offset %llu.", @@ -460,8 +460,6 @@ xfs_discard_page( i_blocks_per_page(inode, page) - pageoff_fsb); if (error && !xfs_is_shutdown(mp)) xfs_alert(mp, "page discard unable to remove delalloc mapping."); -out_invalidate: - iomap_invalidatepage(page, pageoff, PAGE_SIZE - pageoff); } static const struct iomap_writeback_ops xfs_writeback_ops = {