summaryrefslogtreecommitdiffstats
path: root/fs/ext4/inode.c
diff options
context:
space:
mode:
authorJan Kara <jack@suse.cz>2023-03-29 17:49:44 +0200
committerTheodore Ts'o <tytso@mit.edu>2023-04-14 20:02:37 -0400
commitd0ab8368c175f7b5ef0851283a2ba362a9ab327a (patch)
treecd67b2d62450dcc62fbc70a18fae5afda77b2c4c /fs/ext4/inode.c
parentab382539adcb43f52d984abf58d8e3459cd707a2 (diff)
downloadlinux-d0ab8368c175f7b5ef0851283a2ba362a9ab327a.tar.gz
linux-d0ab8368c175f7b5ef0851283a2ba362a9ab327a.tar.bz2
linux-d0ab8368c175f7b5ef0851283a2ba362a9ab327a.zip
Revert "ext4: Fix warnings when freezing filesystem with journaled data"
After making ext4_writepages() properly clean all pages there is no need for special treatment of filesystem freezing. Revert commit e6c28a26b799c7640b77daff3e4a67808c74381c. Signed-off-by: Jan Kara <jack@suse.cz> Link: https://lore.kernel.org/r/20230329154950.19720-13-jack@suse.cz Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Diffstat (limited to 'fs/ext4/inode.c')
-rw-r--r--fs/ext4/inode.c15
1 files changed, 1 insertions, 14 deletions
diff --git a/fs/ext4/inode.c b/fs/ext4/inode.c
index c1888cd2a48f..8dbd352e3986 100644
--- a/fs/ext4/inode.c
+++ b/fs/ext4/inode.c
@@ -2385,7 +2385,6 @@ static int mpage_journal_page_buffers(handle_t *handle,
static int mpage_prepare_extent_to_map(struct mpage_da_data *mpd)
{
struct address_space *mapping = mpd->inode->i_mapping;
- struct super_block *sb = mpd->inode->i_sb;
struct folio_batch fbatch;
unsigned int nr_folios;
pgoff_t index = mpd->first_page;
@@ -2405,15 +2404,7 @@ static int mpage_prepare_extent_to_map(struct mpage_da_data *mpd)
mpd->map.m_len = 0;
mpd->next_page = index;
- /*
- * Start a transaction for writeback of journalled data. We don't start
- * the transaction if the filesystem is frozen. In that case we
- * should not have any dirty data to write anymore but possibly there
- * are stray page dirty bits left by the checkpointing code so this
- * loop clears them.
- */
- if (ext4_should_journal_data(mpd->inode) &&
- sb->s_writers.frozen < SB_FREEZE_FS) {
+ if (ext4_should_journal_data(mpd->inode)) {
handle = ext4_journal_start(mpd->inode, EXT4_HT_WRITE_PAGE,
bpp);
if (IS_ERR(handle))
@@ -2502,15 +2493,11 @@ static int mpage_prepare_extent_to_map(struct mpage_da_data *mpd)
* through a pin.
*/
if (!mpd->can_map) {
- WARN_ON_ONCE(sb->s_writers.frozen ==
- SB_FREEZE_COMPLETE);
err = mpage_submit_folio(mpd, folio);
if (err < 0)
goto out;
/* Pending dirtying of journalled data? */
if (folio_test_checked(folio)) {
- WARN_ON_ONCE(sb->s_writers.frozen >=
- SB_FREEZE_FS);
err = mpage_journal_page_buffers(handle,
mpd, &folio->page);
if (err < 0)