]> git.baikalelectronics.ru Git - kernel.git/commit
f2fs: fix to avoid race in between aio and gc
authorChao Yu <yuchao0@huawei.com>
Wed, 23 Aug 2017 10:23:24 +0000 (18:23 +0800)
committerJaegeuk Kim <jaegeuk@kernel.org>
Tue, 29 Aug 2017 17:05:42 +0000 (10:05 -0700)
commitbb3a1d176c1033922428738a7853edfc3b30db57
treeb5e98beda61c198a551f67e4284c606e2ef88705
parentea44b2f11e56dc5d5774f8f1a88c17c663c67914
f2fs: fix to avoid race in between aio and gc

We won't wait DIO synchronously when doing AIO, so there will be potential
IO reorder in between AIO and GC, which will cause data corruption.

This patch adds inode_dio_wait to serialize aio and data GC to avoid this
issue.

Signed-off-by: Chao Yu <yuchao0@huawei.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
fs/f2fs/gc.c