f2fs: wake up all waiters in f2fs_submit_discard_endio
authorChao Yu <yuchao0@huawei.com>
Fri, 19 May 2017 15:46:44 +0000 (23:46 +0800)
committerJaegeuk Kim <jaegeuk@kernel.org>
Wed, 24 May 2017 04:09:54 +0000 (21:09 -0700)
commite31b98215779e66a490471c6ad886ae231316699
tree01a15476b920f5178ec0029a6b305fe193589189
parent04dfc23006a200865132ef404778a07b896a0280
f2fs: wake up all waiters in f2fs_submit_discard_endio

There could be more than one waiter waiting discard IO completion, so we
need use complete_all() instead of complete() in f2fs_submit_discard_endio
to avoid hungtask.

Fixes: ec9895add2c5 ("f2fs: don't hold cmd_lock during waiting discard
command")
Cc: <stable@vger.kernel.org>
Signed-off-by: Chao Yu <yuchao0@huawei.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
fs/f2fs/segment.c