Skip to content

Commit

Permalink
block: Remove REQ_OP_ZONE_RESET plugging
Browse files Browse the repository at this point in the history
REQ_OP_ZONE_RESET operations cannot be merged as these bios and requests
do not have a size and are never sequential due to the zone start sector
position required for their execution. As a result, there is no point in
using a plug around blkdev_reset_zones() bio issuing loop. This patch
removes this unnecessary plugging.

Reviewed-by: Chaitanya Kulkarni <chaitanya.kulkarni@wdc.com>
Reviewed-by: Javier González <javier@javigon.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Damien Le Moal <damien.lemoal@wdc.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
  • Loading branch information
Damien Le Moal authored and Jens Axboe committed Nov 7, 2019
1 parent f8db383 commit a84324d
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions block/blk-zoned.c
Original file line number Diff line number Diff line change
Expand Up @@ -258,7 +258,6 @@ int blkdev_reset_zones(struct block_device *bdev,
sector_t zone_sectors;
sector_t end_sector = sector + nr_sectors;
struct bio *bio = NULL;
struct blk_plug plug;
int ret;

if (!blk_queue_is_zoned(q))
Expand All @@ -283,7 +282,6 @@ int blkdev_reset_zones(struct block_device *bdev,
end_sector != bdev->bd_part->nr_sects)
return -EINVAL;

blk_start_plug(&plug);
while (sector < end_sector) {

bio = blk_next_bio(bio, 0, gfp_mask);
Expand All @@ -301,8 +299,6 @@ int blkdev_reset_zones(struct block_device *bdev,
ret = submit_bio_wait(bio);
bio_put(bio);

blk_finish_plug(&plug);

return ret;
}
EXPORT_SYMBOL_GPL(blkdev_reset_zones);
Expand Down

0 comments on commit a84324d

Please sign in to comment.