> index 21108a550fbf..3b0c5cfe922a 100644 > --- a/block/blk-flush.c > +++ b/block/blk-flush.c > @@ -236,12 +236,10 @@ static void flush_end_io(struct request *flush_rq, blk_status_t error) > error = fq->rq_status; > > hctx = flush_rq->mq_hctx; > + if (!q->elevator) > flush_rq->tag = -1; > + else > flush_rq->internal_tag = -1; These should switch to BLK_MQ_NO_TAG which you're at it. > - if (!(data->flags & BLK_MQ_REQ_INTERNAL)) > - blk_mq_tag_busy(data->hctx); BLK_MQ_REQ_INTERNAL is gone now, so this won't apply. > static bool blk_mq_get_driver_tag(struct request *rq) > { > + struct blk_mq_hw_ctx *hctx = rq->mq_hctx; > + bool shared = blk_mq_tag_busy(rq->mq_hctx); > + > + if (rq->tag == BLK_MQ_NO_TAG && !__blk_mq_get_driver_tag(rq)) > + return false; > + > + if (shared) { > + rq->rq_flags |= RQF_MQ_INFLIGHT; > + atomic_inc(&hctx->nr_active); > + } > + hctx->tags->rqs[rq->tag] = rq; > + return true; > } The function seems a bit misnamed now, although I don't have a good suggestion for a better name.