summaryrefslogtreecommitdiff
path: root/block/blk-mq.c
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2021-10-12 13:12:18 +0200
committerJens Axboe <axboe@kernel.dk>2021-10-18 06:17:36 -0600
commit28a1ae6b9daba6ac65700eeb38479bd6fadec089 (patch)
tree3a225109e30871e2e06cd9a439bde0f26b9ced7d /block/blk-mq.c
parentefbabbe121f96d4b1a98a2c2ef5d2e8f7fb41c87 (diff)
blk-mq: remove blk_qc_t_valid
Move the trivial check into the only caller. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Reviewed-by: Chaitanya Kulkarni <chaitanya.kulkarni@wdc.com> Tested-by: Mark Wunderlich <mark.wunderlich@intel.com> Link: https://lore.kernel.org/r/20211012111226.760968-9-hch@lst.de Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'block/blk-mq.c')
-rw-r--r--block/blk-mq.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/block/blk-mq.c b/block/blk-mq.c
index 24a10c973f79..7d0d947921a6 100644
--- a/block/blk-mq.c
+++ b/block/blk-mq.c
@@ -4098,7 +4098,7 @@ static int blk_mq_poll_classic(struct request_queue *q, blk_qc_t cookie,
*/
int blk_poll(struct request_queue *q, blk_qc_t cookie, bool spin)
{
- if (!blk_qc_t_valid(cookie) ||
+ if (cookie == BLK_QC_T_NONE ||
!test_bit(QUEUE_FLAG_POLL, &q->queue_flags))
return 0;