diff options
author | Jeff Moyer <jmoyer@redhat.com> | 2011-01-06 20:41:42 +0100 |
---|---|---|
committer | Jens Axboe <jaxboe@fusionio.com> | 2011-01-07 08:43:55 +0100 |
commit | b7908c1035af7652cd613991b54dbff9c8b6bd3a (patch) | |
tree | 91dc24bbb1299ba7f84e22bbaffd28950dd04713 /include/trace/events/block.h | |
parent | 6c23a9681c0fe7fb7dd331b39dda11926f43746e (diff) |
block: trace event block fix unassigned field
The "error" field in block_bio_complete is not assigned, leaving the memory area
uninitialized (keeping garbage data). Pass an additional tracepoint argument to
this event to initialize this field.
Signed-off-by: Jeff Moyer <jmoyer@redhat.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
CC: Steven Rostedt <rostedt@goodmis.org>
CC: Frederic Weisbecker <fweisbec@gmail.com>
CC: Ingo Molnar <mingo@elte.hu>
CC: Thomas Gleixner <tglx@linutronix.de>
CC: Li Zefan <lizf@cn.fujitsu.com>
CC: Alan.Brunelle@hp.com
Signed-off-by: Jens Axboe <jaxboe@fusionio.com>
Diffstat (limited to 'include/trace/events/block.h')
-rw-r--r-- | include/trace/events/block.h | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/include/trace/events/block.h b/include/trace/events/block.h index b56c65dc105..aba421d68f6 100644 --- a/include/trace/events/block.h +++ b/include/trace/events/block.h @@ -206,15 +206,16 @@ TRACE_EVENT(block_bio_bounce, * block_bio_complete - completed all work on the block operation * @q: queue holding the block operation * @bio: block operation completed + * @error: io error value * * This tracepoint indicates there is no further work to do on this * block IO operation @bio. */ TRACE_EVENT(block_bio_complete, - TP_PROTO(struct request_queue *q, struct bio *bio), + TP_PROTO(struct request_queue *q, struct bio *bio, int error), - TP_ARGS(q, bio), + TP_ARGS(q, bio, error), TP_STRUCT__entry( __field( dev_t, dev ) @@ -228,6 +229,7 @@ TRACE_EVENT(block_bio_complete, __entry->dev = bio->bi_bdev->bd_dev; __entry->sector = bio->bi_sector; __entry->nr_sector = bio->bi_size >> 9; + __entry->error = error; blk_fill_rwbs(__entry->rwbs, bio->bi_rw, bio->bi_size); ), |