diff options
author | Omar Sandoval <osandov@fb.com> | 2017-05-04 03:31:34 -0400 |
---|---|---|
committer | Jens Axboe <axboe@fb.com> | 2017-05-04 10:25:17 -0400 |
commit | daaadb3e9453ab89c2e113a2d1df8e19e30944cc (patch) | |
tree | 4a72782bd1b32dd4b0757e993644ff98b7cbc9d5 /block/blk-mq-debugfs.c | |
parent | 16b738f651c83a01db057e5db02ec4b830af9130 (diff) |
mq-deadline: add debugfs attributes
Expose the fifo lists, cached next requests, batching state, and
dispatch list. It'd also be possible to add the sorted lists, but there
aren't already seq_file helpers for rbtrees.
Signed-off-by: Omar Sandoval <osandov@fb.com>
Reviewed-by: Hannes Reinecke <hare@suse.com>
Signed-off-by: Jens Axboe <axboe@fb.com>
Diffstat (limited to 'block/blk-mq-debugfs.c')
-rw-r--r-- | block/blk-mq-debugfs.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/block/blk-mq-debugfs.c b/block/blk-mq-debugfs.c index 8ec738f872e5..803aed4d7221 100644 --- a/block/blk-mq-debugfs.c +++ b/block/blk-mq-debugfs.c | |||
@@ -267,9 +267,8 @@ static const char *const rqf_name[] = { | |||
267 | }; | 267 | }; |
268 | #undef RQF_NAME | 268 | #undef RQF_NAME |
269 | 269 | ||
270 | int blk_mq_debugfs_rq_show(struct seq_file *m, void *v) | 270 | int __blk_mq_debugfs_rq_show(struct seq_file *m, struct request *rq) |
271 | { | 271 | { |
272 | struct request *rq = list_entry_rq(v); | ||
273 | const struct blk_mq_ops *const mq_ops = rq->q->mq_ops; | 272 | const struct blk_mq_ops *const mq_ops = rq->q->mq_ops; |
274 | const unsigned int op = rq->cmd_flags & REQ_OP_MASK; | 273 | const unsigned int op = rq->cmd_flags & REQ_OP_MASK; |
275 | 274 | ||
@@ -291,6 +290,12 @@ int blk_mq_debugfs_rq_show(struct seq_file *m, void *v) | |||
291 | seq_puts(m, "}\n"); | 290 | seq_puts(m, "}\n"); |
292 | return 0; | 291 | return 0; |
293 | } | 292 | } |
293 | EXPORT_SYMBOL_GPL(__blk_mq_debugfs_rq_show); | ||
294 | |||
295 | int blk_mq_debugfs_rq_show(struct seq_file *m, void *v) | ||
296 | { | ||
297 | return __blk_mq_debugfs_rq_show(m, list_entry_rq(v)); | ||
298 | } | ||
294 | EXPORT_SYMBOL_GPL(blk_mq_debugfs_rq_show); | 299 | EXPORT_SYMBOL_GPL(blk_mq_debugfs_rq_show); |
295 | 300 | ||
296 | static void *hctx_dispatch_start(struct seq_file *m, loff_t *pos) | 301 | static void *hctx_dispatch_start(struct seq_file *m, loff_t *pos) |