diff options
| author | Chao Yu <yuchao0@huawei.com> | 2018-08-05 23:02:22 +0800 |
|---|---|---|
| committer | Jaegeuk Kim <jaegeuk@kernel.org> | 2018-09-18 14:42:39 -0700 |
| commit | e356f6e4e509586df5cb1e01b0290b49f22abee6 (patch) | |
| tree | b5bf981fc55dd9ad2cdf789c4b9f826b5c3b3e17 /tools/perf/scripts/python/sctop.py | |
| parent | bee931f3f2edf7cd0af619574b92cf36619a7333 (diff) | |
f2fs: avoid race between zero_range and background GC
Thread A Background GC
- f2fs_zero_range
- truncate_pagecache_range
- gc_data_segment
- get_read_data_page
- move_data_page
- set_page_dirty
- set_cold_data
- f2fs_do_zero_range
- dn->data_blkaddr = NEW_ADDR;
- f2fs_set_data_blkaddr
Actually, we don't need to set dirty & checked flag on the page, since
all valid data in the page should be zeroed by zero_range().
Use i_gc_rwsem[WRITE] to avoid such race condition.
Signed-off-by: Chao Yu <yuchao0@huawei.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python/sctop.py')
0 files changed, 0 insertions, 0 deletions
