1. 13 Sep, 2022 2 commits
    • Jaegeuk Kim's avatar
      f2fs: complete checkpoints during remount · 4f99484d
      Jaegeuk Kim authored
      Otherwise, pending checkpoints can contribute a race condition to give a
      quota warning.
      
      - Thread                      - checkpoint thread
                                    add checkpoints to the list
      do_remount()
       down_write(&sb->s_umount);
       f2fs_remount()
                                    block_operations()
                                     down_read_trylock(&sb->s_umount) = 0
       up_write(&sb->s_umount);
                                     f2fs_quota_sync()
                                      dquot_writeback_dquots()
                                       WARN_ON_ONCE(!rwsem_is_locked(&sb->s_umount));
      
      Or,
      
      do_remount()
       down_write(&sb->s_umount);
       f2fs_remount()
                                    create a ckpt thread
                                    f2fs_enable_checkpoint() adds checkpoints
      			      wait for f2fs_sync_fs()
                                    trigger another pending checkpoint
                                     block_operations()
                                      down_read_trylock(&sb->s_umount) = 0
       up_write(&sb->s_umount);
                                      f2fs_quota_sync()
                                       dquot_writeback_dquots()
                                        WARN_ON_ONCE(!rwsem_is_locked(&sb->s_umount));
      
      Cc: stable@vger.kernel.org
      Reviewed-by: default avatarChao Yu <chao@kernel.org>
      Signed-off-by: default avatarJaegeuk Kim <jaegeuk@kernel.org>
      4f99484d
    • Jaegeuk Kim's avatar
      f2fs: flush pending checkpoints when freezing super · c7b58576
      Jaegeuk Kim authored
      This avoids -EINVAL when trying to freeze f2fs.
      
      Cc: stable@vger.kernel.org
      Reviewed-by: default avatarChao Yu <chao@kernel.org>
      Signed-off-by: default avatarJaegeuk Kim <jaegeuk@kernel.org>
      c7b58576
  2. 30 Aug, 2022 5 commits
  3. 29 Aug, 2022 2 commits
  4. 28 Aug, 2022 25 commits
  5. 27 Aug, 2022 6 commits