summaryrefslogtreecommitdiff
path: root/blkparse_fmt.c
diff options
context:
space:
mode:
authorJens Axboe <axboe@suse.de>2006-07-23 02:13:20 +0200
committerJens Axboe <axboe@suse.de>2006-07-23 02:13:20 +0200
commit711e4d252464a658aeca93593a985383eeeb8b7f (patch)
tree81f5ea8509706107d472454383a131e3118a83ca /blkparse_fmt.c
parentf86990edd23e465f8a865c34d308f888b8e6ee2d (diff)
downloadblktrace-711e4d252464a658aeca93593a985383eeeb8b7f.tar.gz
blktrace-711e4d252464a658aeca93593a985383eeeb8b7f.tar.bz2
[PATCH] Support for logging metadata IO requests
Diffstat (limited to 'blkparse_fmt.c')
-rw-r--r--blkparse_fmt.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/blkparse_fmt.c b/blkparse_fmt.c
index fdbe2dd..b97f46a 100644
--- a/blkparse_fmt.c
+++ b/blkparse_fmt.c
@@ -66,6 +66,7 @@ static inline void fill_rwbs(char *rwbs, struct blk_io_trace *t)
int a = t->action & BLK_TC_ACT(BLK_TC_AHEAD);
int b = t->action & BLK_TC_ACT(BLK_TC_BARRIER);
int s = t->action & BLK_TC_ACT(BLK_TC_SYNC);
+ int m = t->action & BLK_TC_ACT(BLK_TC_META);
int i = 0;
if (w)
@@ -78,6 +79,8 @@ static inline void fill_rwbs(char *rwbs, struct blk_io_trace *t)
rwbs[i++] = 'B';
if (s)
rwbs[i++] = 'S';
+ if (m)
+ rwbs[i++] = 'M';
rwbs[i] = '\0';
}
@@ -164,7 +167,7 @@ static void print_field(char *act, struct per_cpu_info *pci,
break;
}
case 'd': {
- char rwbs[4];
+ char rwbs[6];
fill_rwbs(rwbs, t);
fprintf(ofp, strcat(format, "s"), rwbs);
@@ -258,7 +261,7 @@ static void process_default(char *act, struct per_cpu_info *pci,
struct blk_io_trace *t, unsigned long long elapsed,
int pdu_len, unsigned char *pdu_buf)
{
- char rwbs[4];
+ char rwbs[6];
char *name;
fill_rwbs(rwbs, t);