Skip to content

Commit f01b411

Browse files
Christoph Hellwigaxboe
authored andcommitted
Revert "blkdev: check for valid request queue before issuing flush"
This reverts commit f10d9f6. We can't have queues without a make_request_fn any more (and the loop device uses blk-mq these days anyway..). Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jens Axboe <axboe@kernel.dk>
1 parent 3d745ea commit f01b411

1 file changed

Lines changed: 0 additions & 9 deletions

File tree

‎block/blk-flush.c‎

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -454,15 +454,6 @@ int blkdev_issue_flush(struct block_device *bdev, gfp_t gfp_mask,
454454
if (!q)
455455
return -ENXIO;
456456

457-
/*
458-
* some block devices may not have their queue correctly set up here
459-
* (e.g. loop device without a backing file) and so issuing a flush
460-
* here will panic. Ensure there is a request function before issuing
461-
* the flush.
462-
*/
463-
if (!q->make_request_fn)
464-
return -ENXIO;
465-
466457
bio = bio_alloc(gfp_mask, 0);
467458
bio_set_dev(bio, bdev);
468459
bio->bi_opf = REQ_OP_WRITE | REQ_PREFLUSH;

0 commit comments

Comments
 (0)