diff options
author | Christoph Hellwig <hch@lst.de> | 2014-04-15 16:14:00 -0400 |
---|---|---|
committer | Jens Axboe <axboe@fb.com> | 2014-04-15 16:18:02 -0400 |
commit | 24d2f90309b23f2cfe016b2aebc5f0d6e01c57fd (patch) | |
tree | 10307829129eb8f96facbb89fefbba3c0032fb46 /block/blk-mq.h | |
parent | ed44832dea8a74f909e0187f350201402927f5e5 (diff) |
blk-mq: split out tag initialization, support shared tags
Add a new blk_mq_tag_set structure that gets set up before we initialize
the queue. A single blk_mq_tag_set structure can be shared by multiple
queues.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Modular export of blk_mq_{alloc,free}_tagset added by me.
Signed-off-by: Jens Axboe <axboe@fb.com>
Diffstat (limited to 'block/blk-mq.h')
-rw-r--r-- | block/blk-mq.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/block/blk-mq.h b/block/blk-mq.h index 7964dadb7d64..5fa14f19f752 100644 --- a/block/blk-mq.h +++ b/block/blk-mq.h | |||
@@ -1,6 +1,8 @@ | |||
1 | #ifndef INT_BLK_MQ_H | 1 | #ifndef INT_BLK_MQ_H |
2 | #define INT_BLK_MQ_H | 2 | #define INT_BLK_MQ_H |
3 | 3 | ||
4 | struct blk_mq_tag_set; | ||
5 | |||
4 | struct blk_mq_ctx { | 6 | struct blk_mq_ctx { |
5 | struct { | 7 | struct { |
6 | spinlock_t lock; | 8 | spinlock_t lock; |
@@ -46,8 +48,7 @@ void blk_mq_disable_hotplug(void); | |||
46 | /* | 48 | /* |
47 | * CPU -> queue mappings | 49 | * CPU -> queue mappings |
48 | */ | 50 | */ |
49 | struct blk_mq_reg; | 51 | extern unsigned int *blk_mq_make_queue_map(struct blk_mq_tag_set *set); |
50 | extern unsigned int *blk_mq_make_queue_map(struct blk_mq_reg *reg); | ||
51 | extern int blk_mq_update_queue_map(unsigned int *map, unsigned int nr_queues); | 52 | extern int blk_mq_update_queue_map(unsigned int *map, unsigned int nr_queues); |
52 | 53 | ||
53 | void blk_mq_add_timer(struct request *rq); | 54 | void blk_mq_add_timer(struct request *rq); |