Re: [RFC 4/5] ext4: add fs freezing support on suspend/hibernation

From: Theodore Ts'o
Date: Tue Oct 03 2017 - 15:59:59 EST


On Tue, Oct 03, 2017 at 11:53:12AM -0700, Luis R. Rodriguez wrote:
> @@ -4926,7 +4926,7 @@ static int ext4_unfreeze(struct super_block *sb)
> ext4_set_feature_journal_needs_recovery(sb);
> }
>
> - ext4_commit_super(sb, 1);
> + ext4_commit_super(sb, 0);
> return 0;
> }
>

After we remove add the NEEDS_RECOVERY flag, we need to make sure
recovery flag is pushed out to disk before any other changes are
allowed to be pushed out to disk. That's why we originally did the
update synchronously.

There are other ways we could fulfill this requirements, but doing a
synchronous update is the simplest way to handle this. Was it
necessary to change this given the other changes you are making the fs
freeze implementation?

- Ted