+ res = sbitmap_init_node(&shared_sb,
+ set->__bitmap_tags.sb.depth,
+ set->__bitmap_tags.sb.shift,
+ GFP_KERNEL, NUMA_NO_NODE);
+ if (res)
+ return res;
+ sb = &shared_sb;
+
+ res = mutex_lock_interruptible(&q->sysfs_lock);
+ if (res)
+ goto out;
+ if (hctx->tags) {
+ hctx_filter_sb(sb, hctx);
+ sbitmap_bitmap_show(sb, m);
+ }
+
+ mutex_unlock(&q->sysfs_lock);
+
+out:
+ sbitmap_free(&shared_sb);
+ return res;
+}
+
static int hctx_tags_bitmap_show(void *data, struct seq_file *m)
{
struct blk_mq_hw_ctx *hctx = data;
@@ -823,6 +884,7 @@ static const struct blk_mq_debugfs_attr
blk_mq_debugfs_hctx_shared_sbitmap_attrs
{"busy", 0400, hctx_busy_show},
{"ctx_map", 0400, hctx_ctx_map_show},
{"tags", 0400, hctx_tags_show},
+ {"tags_bitmap", 0400, hctx_tags_shared_sbitmap_bitmap_show},
{"sched_tags", 0400, hctx_sched_tags_show},
{"sched_tags_bitmap", 0400, hctx_sched_tags_bitmap_show},
{"io_poll", 0600, hctx_io_poll_show, hctx_io_poll_write},