diff options
author | Steven Whitehouse <swhiteho@redhat.com> | 2009-06-12 03:49:20 -0400 |
---|---|---|
committer | Steven Whitehouse <swhiteho@redhat.com> | 2009-06-12 03:49:20 -0400 |
commit | 63997775b795f97ef51f3e56bc3abc9edc04bbb0 (patch) | |
tree | 607519910f92b1101fbe0223c301c503001bc0ef /fs/gfs2/bmap.c | |
parent | 8ebf975608aaebd7feb33d77f07ba21a6380e086 (diff) |
GFS2: Add tracepoints
This patch adds the ability to trace various aspects of the GFS2
filesystem. The trace points are divided into three groups,
glocks, logging and bmap. These points have been chosen because
they allow inspection of the major internal functions of GFS2
and they are also generic enough that they are unlikely to need
any major changes as the filesystem evolves.
Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
Diffstat (limited to 'fs/gfs2/bmap.c')
-rw-r--r-- | fs/gfs2/bmap.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/fs/gfs2/bmap.c b/fs/gfs2/bmap.c index 329763530dc0..6d47379e794b 100644 --- a/fs/gfs2/bmap.c +++ b/fs/gfs2/bmap.c | |||
@@ -25,6 +25,7 @@ | |||
25 | #include "trans.h" | 25 | #include "trans.h" |
26 | #include "dir.h" | 26 | #include "dir.h" |
27 | #include "util.h" | 27 | #include "util.h" |
28 | #include "trace_gfs2.h" | ||
28 | 29 | ||
29 | /* This doesn't need to be that large as max 64 bit pointers in a 4k | 30 | /* This doesn't need to be that large as max 64 bit pointers in a 4k |
30 | * block is 512, so __u16 is fine for that. It saves stack space to | 31 | * block is 512, so __u16 is fine for that. It saves stack space to |
@@ -589,6 +590,7 @@ int gfs2_block_map(struct inode *inode, sector_t lblock, | |||
589 | clear_buffer_mapped(bh_map); | 590 | clear_buffer_mapped(bh_map); |
590 | clear_buffer_new(bh_map); | 591 | clear_buffer_new(bh_map); |
591 | clear_buffer_boundary(bh_map); | 592 | clear_buffer_boundary(bh_map); |
593 | trace_gfs2_bmap(ip, bh_map, lblock, create, 1); | ||
592 | if (gfs2_is_dir(ip)) { | 594 | if (gfs2_is_dir(ip)) { |
593 | bsize = sdp->sd_jbsize; | 595 | bsize = sdp->sd_jbsize; |
594 | arr = sdp->sd_jheightsize; | 596 | arr = sdp->sd_jheightsize; |
@@ -623,6 +625,7 @@ int gfs2_block_map(struct inode *inode, sector_t lblock, | |||
623 | ret = 0; | 625 | ret = 0; |
624 | out: | 626 | out: |
625 | release_metapath(&mp); | 627 | release_metapath(&mp); |
628 | trace_gfs2_bmap(ip, bh_map, lblock, create, ret); | ||
626 | bmap_unlock(ip, create); | 629 | bmap_unlock(ip, create); |
627 | return ret; | 630 | return ret; |
628 | 631 | ||