diff options
author | Xiaoguang Wang <wangxg.fnst@cn.fujitsu.com> | 2015-03-30 01:19:14 -0400 |
---|---|---|
committer | Jens Axboe <axboe@fb.com> | 2015-03-30 11:04:27 -0400 |
commit | f9018ac9308ea415e659cfbdda040504ef92597b (patch) | |
tree | 291929592e7fcbc757d94138728249eb48ab8169 /block | |
parent | 271508dba2c3fc307e7c44e2731a2ece70a4025e (diff) |
block: remove redundant check about 'set->nr_hw_queues' in blk_mq_alloc_tag_set()
At the beginning of blk_mq_alloc_tag_set(), we have already checked whether
'set->nr_hw_queues' is zero, so here remove this redundant check.
Signed-off-by: Xiaoguang Wang <wangxg.fnst@cn.fujitsu.com>
Signed-off-by: Jens Axboe <axboe@fb.com>
Diffstat (limited to 'block')
-rw-r--r-- | block/blk-mq.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/block/blk-mq.c b/block/blk-mq.c index 59fa23935a0f..37f14362aa15 100644 --- a/block/blk-mq.c +++ b/block/blk-mq.c | |||
@@ -2174,7 +2174,7 @@ int blk_mq_alloc_tag_set(struct blk_mq_tag_set *set) | |||
2174 | if (set->queue_depth < set->reserved_tags + BLK_MQ_TAG_MIN) | 2174 | if (set->queue_depth < set->reserved_tags + BLK_MQ_TAG_MIN) |
2175 | return -EINVAL; | 2175 | return -EINVAL; |
2176 | 2176 | ||
2177 | if (!set->nr_hw_queues || !set->ops->queue_rq || !set->ops->map_queue) | 2177 | if (!set->ops->queue_rq || !set->ops->map_queue) |
2178 | return -EINVAL; | 2178 | return -EINVAL; |
2179 | 2179 | ||
2180 | if (set->queue_depth > BLK_MQ_MAX_DEPTH) { | 2180 | if (set->queue_depth > BLK_MQ_MAX_DEPTH) { |