f2fs: add a punch discard command function
authorYunlei He <heyunlei@huawei.com>
Thu, 2 Mar 2017 02:36:20 +0000 (10:36 +0800)
committerJaegeuk Kim <jaegeuk@kernel.org>
Wed, 22 Mar 2017 02:34:23 +0000 (22:34 -0400)
commit3d6a650febdd762c90fe477aa53b9413fd7d97df
tree0ecbe28982f52c008e4adb9e4612f6c422e7171d
parentc81abe34fe1ec5e60e5cba6adc912d30e44cc40d
f2fs: add a punch discard command function

This patch add a function to punch discard command if one segment
reuse before discard. Split this segment from multi-segments discard
range, and discard the left bigger range.

Signed-off-by: Yunlei He <heyunlei@huawei.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
fs/f2fs/segment.c