blk-mq: prevent unmapped hw queue from being scheduled
authorMing Lei <ming.lei@canonical.com>
Wed, 3 Dec 2014 11:38:04 +0000 (19:38 +0800)
committerJens Axboe <axboe@fb.com>
Tue, 9 Dec 2014 04:37:08 +0000 (21:37 -0700)
commit19c66e59ce57e7b181625cbb408d48eb10837763
tree4eb5617cb983d279305e7b9f7e65cf61f0175d2a
parent080ff3511450fd73948697fef34a3cc382675b59
blk-mq: prevent unmapped hw queue from being scheduled

When one hardware queue has no mapped software queues, it
shouldn't have been scheduled. Otherwise WARNING or OOPS
can triggered.

blk_mq_hw_queue_mapped() helper is introduce for fixing
the problem.

Signed-off-by: Ming Lei <ming.lei@canonical.com>
Signed-off-by: Jens Axboe <axboe@fb.com>
block/blk-mq.c
block/blk-mq.h