diff options
author | Jaegeuk Kim <jaegeuk@kernel.org> | 2016-09-06 23:31:56 +0300 |
---|---|---|
committer | Jaegeuk Kim <jaegeuk@kernel.org> | 2016-09-08 04:53:50 +0300 |
commit | 68f313935fb205822ed1f923f7833639f3c78573 (patch) | |
tree | e6c040551f799bc84760ef71b01b3339c9be3932 /fs/f2fs/data.c | |
parent | 7732c26ac3925e2aebfa84e14673240201ddc9de (diff) | |
download | linux-68f313935fb205822ed1f923f7833639f3c78573.tar.xz |
f2fs: no need to make zeros beyond i_size
We don't need to make zeros beyond i_size, since we already wrote that through
NEW_ADDR case.
Reported-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Diffstat (limited to 'fs/f2fs/data.c')
-rw-r--r-- | fs/f2fs/data.c | 9 |
1 files changed, 0 insertions, 9 deletions
diff --git a/fs/f2fs/data.c b/fs/f2fs/data.c index 7c8e219f93dc..8ffb480935b3 100644 --- a/fs/f2fs/data.c +++ b/fs/f2fs/data.c @@ -1647,15 +1647,6 @@ repeat: if (PageUptodate(page)) goto out_clear; - if ((pos & PAGE_MASK) >= i_size_read(inode)) { - unsigned start = pos & (PAGE_SIZE - 1); - unsigned end = start + len; - - /* Reading beyond i_size is simple: memset to zero */ - zero_user_segments(page, 0, start, end, PAGE_SIZE); - goto out_update; - } - if (blkaddr == NEW_ADDR) { zero_user_segment(page, 0, PAGE_SIZE); } else { |