summaryrefslogtreecommitdiffstats
path: root/fs/f2fs/checkpoint.c
diff options
context:
space:
mode:
authorNamjae Jeon <namjae.jeon@samsung.com>2013-05-23 22:57:53 +0900
committerJaegeuk Kim <jaegeuk.kim@samsung.com>2013-05-28 15:03:05 +0900
commit35b09d82c3cf3fc0b8b6d923e7fd82ff7926aafc (patch)
treee92d7f02e6bbd19c194cd6363f1c5b0545e20523 /fs/f2fs/checkpoint.c
parenta9841c4dbbdd8a2fb919ea305ffa95ab5ec80af2 (diff)
downloadlinux-35b09d82c3cf3fc0b8b6d923e7fd82ff7926aafc.tar.bz2
f2fs: push some variables to debug part
Some, counters are needed only for the statistical information while debugging. So, those can be controlled using CONFIG_F2FS_STAT_FS, pushing the usage for few variables under this flag. Signed-off-by: Namjae Jeon <namjae.jeon@samsung.com> Signed-off-by: Amit Sahrawat <a.sahrawat@samsung.com> Signed-off-by: Jaegeuk Kim <jaegeuk.kim@samsung.com>
Diffstat (limited to 'fs/f2fs/checkpoint.c')
-rw-r--r--fs/f2fs/checkpoint.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/fs/f2fs/checkpoint.c b/fs/f2fs/checkpoint.c
index 3d1144908ac6..01ddc911ac9b 100644
--- a/fs/f2fs/checkpoint.c
+++ b/fs/f2fs/checkpoint.c
@@ -478,7 +478,9 @@ retry:
}
}
list_add_tail(&new->list, head);
+#ifdef CONFIG_F2FS_STAT_FS
sbi->n_dirty_dirs++;
+#endif
BUG_ON(!S_ISDIR(inode->i_mode));
out:
@@ -508,7 +510,9 @@ void remove_dirty_dir_inode(struct inode *inode)
if (entry->inode == inode) {
list_del(&entry->list);
kmem_cache_free(inode_entry_slab, entry);
+#ifdef CONFIG_F2FS_STAT_FS
sbi->n_dirty_dirs--;
+#endif
break;
}
}