Merge tag 'scsi-misc' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi
[linux-2.6-microblaze.git] / block / blk-mq.c
index 2e825a7..466676b 100644 (file)
@@ -361,11 +361,12 @@ static struct request *__blk_mq_alloc_request(struct blk_mq_alloc_data *data)
 
        if (e) {
                /*
-                * Flush requests are special and go directly to the
+                * Flush/passthrough requests are special and go directly to the
                 * dispatch list. Don't include reserved tags in the
                 * limiting, as it isn't useful.
                 */
                if (!op_is_flush(data->cmd_flags) &&
+                   !blk_op_is_passthrough(data->cmd_flags) &&
                    e->type->ops.limit_depth &&
                    !(data->flags & BLK_MQ_REQ_RESERVED))
                        e->type->ops.limit_depth(data->cmd_flags, data);
@@ -1905,7 +1906,8 @@ void blk_mq_insert_requests(struct blk_mq_hw_ctx *hctx, struct blk_mq_ctx *ctx,
        spin_unlock(&ctx->lock);
 }
 
-static int plug_rq_cmp(void *priv, struct list_head *a, struct list_head *b)
+static int plug_rq_cmp(void *priv, const struct list_head *a,
+                      const struct list_head *b)
 {
        struct request *rqa = container_of(a, struct request, queuelist);
        struct request *rqb = container_of(b, struct request, queuelist);