+DECLARE_EVENT_CLASS(block_bio,
+
+ TP_PROTO(struct request_queue *q, struct bio *bio),
+
+ TP_ARGS(q, bio),
+
+ TP_STRUCT__entry(
+ __field( dev_t, dev )
+ __field( sector_t, sector )
+ __field( unsigned int, nr_sector )
+ __field( unsigned int, rwbs )
+ __array_text( char, comm, TASK_COMM_LEN )
+ ),
+
+ TP_fast_assign(
+ tp_assign(dev, bio->bi_bdev ? bio->bi_bdev->bd_dev : 0)
+ tp_assign(sector, bio->bi_sector)
+ tp_assign(nr_sector, bio->bi_size >> 9)
+ blk_fill_rwbs(rwbs, bio->bi_rw, bio->bi_size)
+ tp_memcpy(comm, current->comm, TASK_COMM_LEN)
+ ),
+
+ TP_printk("%d,%d %s %llu + %u [%s]",
+ MAJOR(__entry->dev), MINOR(__entry->dev),
+ __print_rwbs_flags(__entry->rwbs),
+ (unsigned long long)__entry->sector,
+ __entry->nr_sector, __entry->comm)
+)
+
+/**
+ * block_bio_backmerge - merging block operation to the end of an existing operation
+ * @q: queue holding operation
+ * @bio: new block operation to merge
+ *
+ * Merging block request @bio to the end of an existing block request
+ * in queue @q.
+ */
+DEFINE_EVENT(block_bio, block_bio_backmerge,
+