aboutsummaryrefslogtreecommitdiffstats
path: root/fs/ext4/super.c
diff options
context:
space:
mode:
authorLeah Rumancik <leah.rumancik@gmail.com>2021-05-18 15:13:25 +0000
committerTheodore Ts'o <tytso@mit.edu>2021-06-22 19:27:10 -0400
commit01d5d96542fd4e383da79593f8a3450995ce2257 (patch)
treecc7fc418d36a2cda0f939cc19a499c8d2bce953e /fs/ext4/super.c
parentext4: return error code when ext4_fill_flex_info() fails (diff)
downloadlinux-dev-01d5d96542fd4e383da79593f8a3450995ce2257.tar.xz
linux-dev-01d5d96542fd4e383da79593f8a3450995ce2257.zip
ext4: add discard/zeroout flags to journal flush
Add a flags argument to jbd2_journal_flush to enable discarding or zero-filling the journal blocks while flushing the journal. Signed-off-by: Leah Rumancik <leah.rumancik@gmail.com> Link: https://lore.kernel.org/r/20210518151327.130198-1-leah.rumancik@gmail.com Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Diffstat (limited to 'fs/ext4/super.c')
-rw-r--r--fs/ext4/super.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/fs/ext4/super.c b/fs/ext4/super.c
index 3b6203543607..ad3919dbd49e 100644
--- a/fs/ext4/super.c
+++ b/fs/ext4/super.c
@@ -5653,7 +5653,7 @@ static int ext4_mark_recovery_complete(struct super_block *sb,
return 0;
}
jbd2_journal_lock_updates(journal);
- err = jbd2_journal_flush(journal);
+ err = jbd2_journal_flush(journal, 0);
if (err < 0)
goto out;
@@ -5795,7 +5795,7 @@ static int ext4_freeze(struct super_block *sb)
* Don't clear the needs_recovery flag if we failed to
* flush the journal.
*/
- error = jbd2_journal_flush(journal);
+ error = jbd2_journal_flush(journal, 0);
if (error < 0)
goto out;
@@ -6389,7 +6389,7 @@ static int ext4_quota_on(struct super_block *sb, int type, int format_id,
* otherwise be livelocked...
*/
jbd2_journal_lock_updates(EXT4_SB(sb)->s_journal);
- err = jbd2_journal_flush(EXT4_SB(sb)->s_journal);
+ err = jbd2_journal_flush(EXT4_SB(sb)->s_journal, 0);
jbd2_journal_unlock_updates(EXT4_SB(sb)->s_journal);
if (err)
return err;