aboutsummaryrefslogtreecommitdiffstats
path: root/fs/ocfs2/buffer_head_io.c
diff options
context:
space:
mode:
authorTao Ma <boyu.mt@taobao.com>2011-03-07 03:43:21 -0500
committerTao Ma <boyu.mt@taobao.com>2011-03-07 03:43:21 -0500
commitc1e8d35ef5ffb393b94a192034b5e3541e005d75 (patch)
treeb9a7f089acd3408c2835a3dfd6aa7bb0407587b3 /fs/ocfs2/buffer_head_io.c
parentef6b689b63b9f5227ccee6f16dd9ee3faf58a464 (diff)
ocfs2: Remove EXIT from masklog.
mlog_exit is used to record the exit status 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. This patch just try to remove it or change it. So: 1. if all the error paths already use mlog_errno, it is just removed. Otherwise, it will be replaced by mlog_errno. 2. if it is used to print some return value, it is replaced with mlog(0,...). mlog_exit_ptr is changed to mlog(0. All those mlog(0,...) will be replaced with trace events later. Signed-off-by: Tao Ma <boyu.mt@taobao.com>
Diffstat (limited to 'fs/ocfs2/buffer_head_io.c')
-rw-r--r--fs/ocfs2/buffer_head_io.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/fs/ocfs2/buffer_head_io.c b/fs/ocfs2/buffer_head_io.c
index 024bd45b7a48..c23846dbfc8f 100644
--- a/fs/ocfs2/buffer_head_io.c
+++ b/fs/ocfs2/buffer_head_io.c
@@ -66,6 +66,7 @@ int ocfs2_write_block(struct ocfs2_super *osb, struct buffer_head *bh,
66 * can get modified during recovery even if read-only. */ 66 * can get modified during recovery even if read-only. */
67 if (ocfs2_is_hard_readonly(osb)) { 67 if (ocfs2_is_hard_readonly(osb)) {
68 ret = -EROFS; 68 ret = -EROFS;
69 mlog_errno(ret);
69 goto out; 70 goto out;
70 } 71 }
71 72
@@ -91,11 +92,11 @@ int ocfs2_write_block(struct ocfs2_super *osb, struct buffer_head *bh,
91 * uptodate. */ 92 * uptodate. */
92 ret = -EIO; 93 ret = -EIO;
93 put_bh(bh); 94 put_bh(bh);
95 mlog_errno(ret);
94 } 96 }
95 97
96 ocfs2_metadata_cache_io_unlock(ci); 98 ocfs2_metadata_cache_io_unlock(ci);
97out: 99out:
98 mlog_exit(ret);
99 return ret; 100 return ret;
100} 101}
101 102
@@ -374,7 +375,6 @@ int ocfs2_read_blocks(struct ocfs2_caching_info *ci, u64 block, int nr,
374 375
375bail: 376bail:
376 377
377 mlog_exit(status);
378 return status; 378 return status;
379} 379}
380 380
@@ -413,6 +413,7 @@ int ocfs2_write_super_or_backup(struct ocfs2_super *osb,
413 413
414 if (ocfs2_is_hard_readonly(osb) || ocfs2_is_soft_readonly(osb)) { 414 if (ocfs2_is_hard_readonly(osb) || ocfs2_is_soft_readonly(osb)) {
415 ret = -EROFS; 415 ret = -EROFS;
416 mlog_errno(ret);
416 goto out; 417 goto out;
417 } 418 }
418 419
@@ -432,9 +433,9 @@ int ocfs2_write_super_or_backup(struct ocfs2_super *osb,
432 if (!buffer_uptodate(bh)) { 433 if (!buffer_uptodate(bh)) {
433 ret = -EIO; 434 ret = -EIO;
434 put_bh(bh); 435 put_bh(bh);
436 mlog_errno(ret);
435 } 437 }
436 438
437out: 439out:
438 mlog_exit(ret);
439 return ret; 440 return ret;
440} 441}