hc
2023-12-11 d2ccde1c8e90d38cee87a1b0309ad2827f3fd30d
kernel/include/trace/events/block.h
....@@ -212,6 +212,21 @@
212212 );
213213
214214 /**
215
+ * block_rq_merge - merge request with another one in the elevator
216
+ * @q: queue holding operation
217
+ * @rq: block IO operation operation request
218
+ *
219
+ * Called when block operation request @rq from queue @q is merged to another
220
+ * request queued in the elevator.
221
+ */
222
+DEFINE_EVENT(block_rq, block_rq_merge,
223
+
224
+ TP_PROTO(struct request_queue *q, struct request *rq),
225
+
226
+ TP_ARGS(q, rq)
227
+);
228
+
229
+/**
215230 * block_bio_bounce - used bounce buffer when processing block operation
216231 * @q: queue holding the block operation
217232 * @bio: block operation
....@@ -254,16 +269,15 @@
254269 * block_bio_complete - completed all work on the block operation
255270 * @q: queue holding the block operation
256271 * @bio: block operation completed
257
- * @error: io error value
258272 *
259273 * This tracepoint indicates there is no further work to do on this
260274 * block IO operation @bio.
261275 */
262276 TRACE_EVENT(block_bio_complete,
263277
264
- TP_PROTO(struct request_queue *q, struct bio *bio, int error),
278
+ TP_PROTO(struct request_queue *q, struct bio *bio),
265279
266
- TP_ARGS(q, bio, error),
280
+ TP_ARGS(q, bio),
267281
268282 TP_STRUCT__entry(
269283 __field( dev_t, dev )
....@@ -277,7 +291,7 @@
277291 __entry->dev = bio_dev(bio);
278292 __entry->sector = bio->bi_iter.bi_sector;
279293 __entry->nr_sector = bio_sectors(bio);
280
- __entry->error = error;
294
+ __entry->error = blk_status_to_errno(bio->bi_status);
281295 blk_fill_rwbs(__entry->rwbs, bio->bi_opf, bio->bi_iter.bi_size);
282296 ),
283297