diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2020-07-10 18:55:46 +0200 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2020-07-10 18:55:46 +0200 |
commit | d33db702745b84fd553d9a5f5db85e122aa45020 (patch) | |
tree | 7aa7071cf686d89e441b001f500e50ab9b16a38c /block | |
parent | Merge tag 'cleanup-kernel_read_write' of git://git.infradead.org/users/hch/misc (diff) | |
parent | nbd: Fix memory leak in nbd_add_socket (diff) | |
download | linux-d33db702745b84fd553d9a5f5db85e122aa45020.tar.xz linux-d33db702745b84fd553d9a5f5db85e122aa45020.zip |
Merge tag 'block-5.8-2020-07-10' of git://git.kernel.dk/linux-block
Pull block fixes from Jens Axboe:
- Fix for inflight accounting, which affects only dm (Ming)
- Fix documentation error for bfq (Yufen)
- Fix memory leak for nbd (Zheng)
* tag 'block-5.8-2020-07-10' of git://git.kernel.dk/linux-block:
nbd: Fix memory leak in nbd_add_socket
blk-mq: consider non-idle request as "inflight" in blk_mq_rq_inflight()
docs: block: update and fix tiny error for bfq
Diffstat (limited to 'block')
-rw-r--r-- | block/blk-mq.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/block/blk-mq.c b/block/blk-mq.c index a9aa6d1e44cf..4e0d173beaa3 100644 --- a/block/blk-mq.c +++ b/block/blk-mq.c @@ -828,10 +828,10 @@ static bool blk_mq_rq_inflight(struct blk_mq_hw_ctx *hctx, struct request *rq, void *priv, bool reserved) { /* - * If we find a request that is inflight and the queue matches, + * If we find a request that isn't idle and the queue matches, * we know the queue is busy. Return false to stop the iteration. */ - if (rq->state == MQ_RQ_IN_FLIGHT && rq->q == hctx->queue) { + if (blk_mq_request_started(rq) && rq->q == hctx->queue) { bool *busy = priv; *busy = true; |