linux-stable/fs/f2fs
Jaegeuk Kim b4b9d34c85 f2fs: remove checkpoint in f2fs_freeze
The generic freeze_super() calls sync_filesystems() before f2fs_freeze().
So, basically we don't need to do checkpoint in f2fs_freeze(). But, in xfs/068,
it triggers circular locking problem below due to gc_mutex for checkpoint.

======================================================
[ INFO: possible circular locking dependency detected ]
4.9.0-rc1+ #132 Tainted: G           OE
-------------------------------------------------------

1. wait for __sb_start_write() by

 [<ffffffff9845f353>] dump_stack+0x85/0xc2
 [<ffffffff980e80bf>] print_circular_bug+0x1cf/0x230
 [<ffffffff980eb4d0>] __lock_acquire+0x19e0/0x1bc0
 [<ffffffff980ebdcb>] lock_acquire+0x11b/0x220
 [<ffffffffc08c7c3b>] ? f2fs_drop_inode+0x9b/0x160 [f2fs]
 [<ffffffff9826bdd0>] __sb_start_write+0x130/0x200
 [<ffffffffc08c7c3b>] ? f2fs_drop_inode+0x9b/0x160 [f2fs]
 [<ffffffffc08c7c3b>] f2fs_drop_inode+0x9b/0x160 [f2fs]
 [<ffffffff98289991>] iput+0x171/0x2c0
 [<ffffffffc08cfccf>] f2fs_sync_inode_meta+0x3f/0xf0 [f2fs]
 [<ffffffffc08cfe04>] block_operations+0x84/0x110 [f2fs]
 [<ffffffffc08cff78>] write_checkpoint+0xe8/0xf20 [f2fs]
 [<ffffffff980e979d>] ? trace_hardirqs_on+0xd/0x10
 [<ffffffffc08c6de9>] ? f2fs_sync_fs+0x79/0x190 [f2fs]
 [<ffffffff9803e9d9>] ? sched_clock+0x9/0x10
 [<ffffffffc08c6de9>] ? f2fs_sync_fs+0x79/0x190 [f2fs]
 [<ffffffffc08c6df5>] f2fs_sync_fs+0x85/0x190 [f2fs]
 [<ffffffff982a4f90>] ? do_fsync+0x70/0x70
 [<ffffffff982a4f90>] ? do_fsync+0x70/0x70
 [<ffffffff982a4fb0>] sync_fs_one_sb+0x20/0x30
 [<ffffffff9826ca3e>] iterate_supers+0xae/0x100
 [<ffffffff982a50b5>] sys_sync+0x55/0x90
 [<ffffffff9890b345>] entry_SYSCALL_64_fastpath+0x23/0xc6

2. wait for sbi->gc_mutex by

 [<ffffffff980ebdcb>] lock_acquire+0x11b/0x220
 [<ffffffff989063d6>] mutex_lock_nested+0x76/0x3f0
 [<ffffffffc08c6de9>] f2fs_sync_fs+0x79/0x190 [f2fs]
 [<ffffffffc08c7a6c>] f2fs_freeze+0x1c/0x20 [f2fs]
 [<ffffffff9826b6ef>] freeze_super+0xcf/0x190
 [<ffffffff9827eebc>] do_vfs_ioctl+0x53c/0x6a0
 [<ffffffff9827f099>] SyS_ioctl+0x79/0x90
 [<ffffffff9890b345>] entry_SYSCALL_64_fastpath+0x23/0xc6

Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
2016-11-23 12:11:29 -08:00
..
acl.c f2fs: keep dirty inodes selectively for checkpoint 2016-11-23 12:11:08 -08:00
acl.h f2fs: remove dead code f2fs_check_acl 2016-09-14 16:52:36 -07:00
checkpoint.c f2fs: make clean inodes when flushing inode page 2016-11-23 12:11:09 -08:00
data.c f2fs: Use generic zoned block device terminology 2016-11-23 12:11:16 -08:00
debug.c f2fs: remove percpu_count due to performance regression 2016-11-23 12:11:10 -08:00
dir.c f2fs: report error of f2fs_fill_dentries 2016-11-23 12:11:12 -08:00
extent_cache.c f2fs: keep dirty inodes selectively for checkpoint 2016-11-23 12:11:08 -08:00
f2fs.h f2fs: Cache zoned block devices zone type 2016-11-23 12:11:22 -08:00
file.c f2fs: keep dirty inodes selectively for checkpoint 2016-11-23 12:11:08 -08:00
gc.c f2fs: give a chance to detach from dirty list 2016-11-23 12:10:51 -08:00
gc.h f2fs: detect idle time depending on user behavior 2016-01-11 15:56:37 -08:00
hash.c f2fs: introduce dot and dotdot name check 2015-05-28 15:41:34 -07:00
inline.c f2fs: report error of f2fs_fill_dentries 2016-11-23 12:11:12 -08:00
inode.c f2fs: record inode updating status correctly 2016-11-23 12:11:25 -08:00
Kconfig f2fs: add mount option to select fault injection ratio 2016-05-07 10:32:22 -07:00
Makefile fs crypto: move per-file encryption from f2fs tree to fs/crypto 2016-03-17 21:19:33 -07:00
namei.c f2fs: keep dirty inodes selectively for checkpoint 2016-11-23 12:11:08 -08:00
node.c f2fs: use BIO_MAX_PAGES for bio allocation 2016-11-23 12:11:07 -08:00
node.h f2fs: split free nid list 2016-11-23 12:11:00 -08:00
recovery.c f2fs: fix wrong i_atime recovery 2016-11-23 12:11:26 -08:00
segment.c f2fs: assign segments correctly for direct_io 2016-11-23 12:11:28 -08:00
segment.h f2fs: use BIO_MAX_PAGES for bio allocation 2016-11-23 12:11:07 -08:00
shrinker.c f2fs: avoid casted negative value as shrink count 2016-11-23 12:11:03 -08:00
super.c f2fs: remove checkpoint in f2fs_freeze 2016-11-23 12:11:29 -08:00
trace.c f2fs: use bio op accessors 2016-06-07 13:41:38 -06:00
trace.h f2fs: add sbi and page pointer in f2fs_io_info 2015-05-28 15:41:32 -07:00
xattr.c f2fs: keep dirty inodes selectively for checkpoint 2016-11-23 12:11:08 -08:00
xattr.h f2fs: add missing argument to f2fs_setxattr stub 2016-03-17 21:19:47 -07:00