aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGu Zheng <guz.fnst@cn.fujitsu.com>2014-03-07 05:43:24 -0500
committerJaegeuk Kim <jaegeuk.kim@samsung.com>2014-03-10 05:45:09 -0400
commitb6ce391e615175029cb8496f03afc9905e0957cc (patch)
treebcc0d5ad69a1bd264c561c22402c352967502bf4
parent20f70751c6b4ac5055be9a0d8a3d3189a81afc5a (diff)
f2fs: update start nid only once each circle
Integrated a couple of minor changes for better readability suggested by Chao Yu. Signed-off-by: Gu Zheng <guz.fnst@cn.fujitsu.com> Reviewed-by: Chao Yu <chao2.yu@samsung.com> Signed-off-by: Jaegeuk Kim <jaegeuk.kim@samsung.com>
-rw-r--r--fs/f2fs/node.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/fs/f2fs/node.c b/fs/f2fs/node.c
index 8c1411060e7e..77b61893fc8d 100644
--- a/fs/f2fs/node.c
+++ b/fs/f2fs/node.c
@@ -1875,11 +1875,9 @@ void destroy_node_manager(struct f2fs_sb_info *sbi)
1875 while ((found = __gang_lookup_nat_cache(nm_i, 1875 while ((found = __gang_lookup_nat_cache(nm_i,
1876 nid, NATVEC_SIZE, natvec))) { 1876 nid, NATVEC_SIZE, natvec))) {
1877 unsigned idx; 1877 unsigned idx;
1878 for (idx = 0; idx < found; idx++) { 1878 nid = nat_get_nid(natvec[found - 1]) + 1;
1879 struct nat_entry *e = natvec[idx]; 1879 for (idx = 0; idx < found; idx++)
1880 nid = nat_get_nid(e) + 1; 1880 __del_from_nat_cache(nm_i, natvec[idx]);
1881 __del_from_nat_cache(nm_i, e);
1882 }
1883 } 1881 }
1884 f2fs_bug_on(nm_i->nat_cnt); 1882 f2fs_bug_on(nm_i->nat_cnt);
1885 write_unlock(&nm_i->nat_tree_lock); 1883 write_unlock(&nm_i->nat_tree_lock);