aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJaegeuk Kim <jaegeuk@kernel.org>2014-12-05 13:51:50 -0500
committerJaegeuk Kim <jaegeuk@kernel.org>2014-12-08 13:35:13 -0500
commit9d1015dd4c6ba602272f80487bb9c922a9a71cc1 (patch)
tree2c641df1ff71cd28567db8e76cd84029738264ab
parent9be32d72becca41d7d9b010d7d9be1d39489414f (diff)
f2fs: count inline_xx in do_read_inode
In do_read_inode, if we failed __recover_inline_status, the inode has inline flag without increasing its count. Later, f2fs_evict_inode will decrease the count, which causes -1. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
-rw-r--r--fs/f2fs/inode.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/fs/f2fs/inode.c b/fs/f2fs/inode.c
index 9fe110ef8cc4..196cc7843aaf 100644
--- a/fs/f2fs/inode.c
+++ b/fs/f2fs/inode.c
@@ -148,6 +148,10 @@ static int do_read_inode(struct inode *inode)
148 __get_inode_rdev(inode, ri); 148 __get_inode_rdev(inode, ri);
149 149
150 f2fs_put_page(node_page, 1); 150 f2fs_put_page(node_page, 1);
151
152 stat_inc_inline_inode(inode);
153 stat_inc_inline_dir(inode);
154
151 return err; 155 return err;
152} 156}
153 157
@@ -199,8 +203,6 @@ make_now:
199 goto bad_inode; 203 goto bad_inode;
200 } 204 }
201 unlock_new_inode(inode); 205 unlock_new_inode(inode);
202 stat_inc_inline_inode(inode);
203 stat_inc_inline_dir(inode);
204 trace_f2fs_iget(inode); 206 trace_f2fs_iget(inode);
205 return inode; 207 return inode;
206 208