diff options
author | Tao Ma <boyu.mt@taobao.com> | 2011-02-20 22:10:44 -0500 |
---|---|---|
committer | Tao Ma <boyu.mt@taobao.com> | 2011-02-20 22:10:44 -0500 |
commit | ef6b689b63b9f5227ccee6f16dd9ee3faf58a464 (patch) | |
tree | ebe3416fcc221e152f2625e8e8794e92e3d8c979 /fs/ocfs2/alloc.c | |
parent | 422e6c4bc4b48c15b3cb57a1ca71431abfc57e54 (diff) |
ocfs2: Remove ENTRY from masklog.
ENTRY is used to record the entry of a function.
But because it is added in so many functions, if we enable it,
the system logs get filled up quickly and cause too much I/O.
So actually no one can open it for a production system or even
for a test.
So for mlog_entry_void, we just remove it.
for mlog_entry(...), we replace it with mlog(0,...), and they
will be replace by trace event later.
Signed-off-by: Tao Ma <boyu.mt@taobao.com>
Diffstat (limited to 'fs/ocfs2/alloc.c')
-rw-r--r-- | fs/ocfs2/alloc.c | 28 |
1 files changed, 2 insertions, 26 deletions
diff --git a/fs/ocfs2/alloc.c b/fs/ocfs2/alloc.c index e4984e259cb6..47a6ce84e67f 100644 --- a/fs/ocfs2/alloc.c +++ b/fs/ocfs2/alloc.c | |||
@@ -965,8 +965,6 @@ int ocfs2_num_free_extents(struct ocfs2_super *osb, | |||
965 | struct buffer_head *eb_bh = NULL; | 965 | struct buffer_head *eb_bh = NULL; |
966 | u64 last_eb_blk = 0; | 966 | u64 last_eb_blk = 0; |
967 | 967 | ||
968 | mlog_entry_void(); | ||
969 | |||
970 | el = et->et_root_el; | 968 | el = et->et_root_el; |
971 | last_eb_blk = ocfs2_et_get_last_eb_blk(et); | 969 | last_eb_blk = ocfs2_et_get_last_eb_blk(et); |
972 | 970 | ||
@@ -1010,8 +1008,6 @@ static int ocfs2_create_new_meta_bhs(handle_t *handle, | |||
1010 | OCFS2_SB(ocfs2_metadata_cache_get_super(et->et_ci)); | 1008 | OCFS2_SB(ocfs2_metadata_cache_get_super(et->et_ci)); |
1011 | struct ocfs2_extent_block *eb; | 1009 | struct ocfs2_extent_block *eb; |
1012 | 1010 | ||
1013 | mlog_entry_void(); | ||
1014 | |||
1015 | count = 0; | 1011 | count = 0; |
1016 | while (count < wanted) { | 1012 | while (count < wanted) { |
1017 | status = ocfs2_claim_metadata(handle, | 1013 | status = ocfs2_claim_metadata(handle, |
@@ -1173,8 +1169,6 @@ static int ocfs2_add_branch(handle_t *handle, | |||
1173 | struct ocfs2_extent_list *el; | 1169 | struct ocfs2_extent_list *el; |
1174 | u32 new_cpos, root_end; | 1170 | u32 new_cpos, root_end; |
1175 | 1171 | ||
1176 | mlog_entry_void(); | ||
1177 | |||
1178 | BUG_ON(!last_eb_bh || !*last_eb_bh); | 1172 | BUG_ON(!last_eb_bh || !*last_eb_bh); |
1179 | 1173 | ||
1180 | if (eb_bh) { | 1174 | if (eb_bh) { |
@@ -1353,8 +1347,6 @@ static int ocfs2_shift_tree_depth(handle_t *handle, | |||
1353 | struct ocfs2_extent_list *root_el; | 1347 | struct ocfs2_extent_list *root_el; |
1354 | struct ocfs2_extent_list *eb_el; | 1348 | struct ocfs2_extent_list *eb_el; |
1355 | 1349 | ||
1356 | mlog_entry_void(); | ||
1357 | |||
1358 | status = ocfs2_create_new_meta_bhs(handle, et, 1, meta_ac, | 1350 | status = ocfs2_create_new_meta_bhs(handle, et, 1, meta_ac, |
1359 | &new_eb_bh); | 1351 | &new_eb_bh); |
1360 | if (status < 0) { | 1352 | if (status < 0) { |
@@ -1446,8 +1438,6 @@ static int ocfs2_find_branch_target(struct ocfs2_extent_tree *et, | |||
1446 | struct buffer_head *bh = NULL; | 1438 | struct buffer_head *bh = NULL; |
1447 | struct buffer_head *lowest_bh = NULL; | 1439 | struct buffer_head *lowest_bh = NULL; |
1448 | 1440 | ||
1449 | mlog_entry_void(); | ||
1450 | |||
1451 | *target_bh = NULL; | 1441 | *target_bh = NULL; |
1452 | 1442 | ||
1453 | el = et->et_root_el; | 1443 | el = et->et_root_el; |
@@ -5795,8 +5785,8 @@ int ocfs2_truncate_log_append(struct ocfs2_super *osb, | |||
5795 | struct ocfs2_dinode *di; | 5785 | struct ocfs2_dinode *di; |
5796 | struct ocfs2_truncate_log *tl; | 5786 | struct ocfs2_truncate_log *tl; |
5797 | 5787 | ||
5798 | mlog_entry("start_blk = %llu, num_clusters = %u\n", | 5788 | mlog(0, "start_blk = %llu, num_clusters = %u\n", |
5799 | (unsigned long long)start_blk, num_clusters); | 5789 | (unsigned long long)start_blk, num_clusters); |
5800 | 5790 | ||
5801 | BUG_ON(mutex_trylock(&tl_inode->i_mutex)); | 5791 | BUG_ON(mutex_trylock(&tl_inode->i_mutex)); |
5802 | 5792 | ||
@@ -5878,8 +5868,6 @@ static int ocfs2_replay_truncate_records(struct ocfs2_super *osb, | |||
5878 | struct inode *tl_inode = osb->osb_tl_inode; | 5868 | struct inode *tl_inode = osb->osb_tl_inode; |
5879 | struct buffer_head *tl_bh = osb->osb_tl_bh; | 5869 | struct buffer_head *tl_bh = osb->osb_tl_bh; |
5880 | 5870 | ||
5881 | mlog_entry_void(); | ||
5882 | |||
5883 | di = (struct ocfs2_dinode *) tl_bh->b_data; | 5871 | di = (struct ocfs2_dinode *) tl_bh->b_data; |
5884 | tl = &di->id2.i_dealloc; | 5872 | tl = &di->id2.i_dealloc; |
5885 | i = le16_to_cpu(tl->tl_used) - 1; | 5873 | i = le16_to_cpu(tl->tl_used) - 1; |
@@ -5949,8 +5937,6 @@ int __ocfs2_flush_truncate_log(struct ocfs2_super *osb) | |||
5949 | struct ocfs2_dinode *di; | 5937 | struct ocfs2_dinode *di; |
5950 | struct ocfs2_truncate_log *tl; | 5938 | struct ocfs2_truncate_log *tl; |
5951 | 5939 | ||
5952 | mlog_entry_void(); | ||
5953 | |||
5954 | BUG_ON(mutex_trylock(&tl_inode->i_mutex)); | 5940 | BUG_ON(mutex_trylock(&tl_inode->i_mutex)); |
5955 | 5941 | ||
5956 | di = (struct ocfs2_dinode *) tl_bh->b_data; | 5942 | di = (struct ocfs2_dinode *) tl_bh->b_data; |
@@ -6032,8 +6018,6 @@ static void ocfs2_truncate_log_worker(struct work_struct *work) | |||
6032 | container_of(work, struct ocfs2_super, | 6018 | container_of(work, struct ocfs2_super, |
6033 | osb_truncate_log_wq.work); | 6019 | osb_truncate_log_wq.work); |
6034 | 6020 | ||
6035 | mlog_entry_void(); | ||
6036 | |||
6037 | status = ocfs2_flush_truncate_log(osb); | 6021 | status = ocfs2_flush_truncate_log(osb); |
6038 | if (status < 0) | 6022 | if (status < 0) |
6039 | mlog_errno(status); | 6023 | mlog_errno(status); |
@@ -6174,8 +6158,6 @@ int ocfs2_complete_truncate_log_recovery(struct ocfs2_super *osb, | |||
6174 | struct inode *tl_inode = osb->osb_tl_inode; | 6158 | struct inode *tl_inode = osb->osb_tl_inode; |
6175 | struct ocfs2_truncate_log *tl; | 6159 | struct ocfs2_truncate_log *tl; |
6176 | 6160 | ||
6177 | mlog_entry_void(); | ||
6178 | |||
6179 | if (OCFS2_I(tl_inode)->ip_blkno == le64_to_cpu(tl_copy->i_blkno)) { | 6161 | if (OCFS2_I(tl_inode)->ip_blkno == le64_to_cpu(tl_copy->i_blkno)) { |
6180 | mlog(ML_ERROR, "Asked to recover my own truncate log!\n"); | 6162 | mlog(ML_ERROR, "Asked to recover my own truncate log!\n"); |
6181 | return -EINVAL; | 6163 | return -EINVAL; |
@@ -6228,8 +6210,6 @@ void ocfs2_truncate_log_shutdown(struct ocfs2_super *osb) | |||
6228 | int status; | 6210 | int status; |
6229 | struct inode *tl_inode = osb->osb_tl_inode; | 6211 | struct inode *tl_inode = osb->osb_tl_inode; |
6230 | 6212 | ||
6231 | mlog_entry_void(); | ||
6232 | |||
6233 | if (tl_inode) { | 6213 | if (tl_inode) { |
6234 | cancel_delayed_work(&osb->osb_truncate_log_wq); | 6214 | cancel_delayed_work(&osb->osb_truncate_log_wq); |
6235 | flush_workqueue(ocfs2_wq); | 6215 | flush_workqueue(ocfs2_wq); |
@@ -6251,8 +6231,6 @@ int ocfs2_truncate_log_init(struct ocfs2_super *osb) | |||
6251 | struct inode *tl_inode = NULL; | 6231 | struct inode *tl_inode = NULL; |
6252 | struct buffer_head *tl_bh = NULL; | 6232 | struct buffer_head *tl_bh = NULL; |
6253 | 6233 | ||
6254 | mlog_entry_void(); | ||
6255 | |||
6256 | status = ocfs2_get_truncate_log_info(osb, | 6234 | status = ocfs2_get_truncate_log_info(osb, |
6257 | osb->slot_num, | 6235 | osb->slot_num, |
6258 | &tl_inode, | 6236 | &tl_inode, |
@@ -7005,8 +6983,6 @@ int ocfs2_commit_truncate(struct ocfs2_super *osb, | |||
7005 | struct ocfs2_extent_tree et; | 6983 | struct ocfs2_extent_tree et; |
7006 | struct ocfs2_cached_dealloc_ctxt dealloc; | 6984 | struct ocfs2_cached_dealloc_ctxt dealloc; |
7007 | 6985 | ||
7008 | mlog_entry_void(); | ||
7009 | |||
7010 | ocfs2_init_dinode_extent_tree(&et, INODE_CACHE(inode), di_bh); | 6986 | ocfs2_init_dinode_extent_tree(&et, INODE_CACHE(inode), di_bh); |
7011 | ocfs2_init_dealloc_ctxt(&dealloc); | 6987 | ocfs2_init_dealloc_ctxt(&dealloc); |
7012 | 6988 | ||