diff options
author | Damien Le Moal <dlemoal@kernel.org> | 2024-06-21 12:15:04 +0900 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2024-06-21 08:26:35 -0600 |
commit | 4ac9056e4bd787f1ba2001167c5acc2b5a75ddf9 (patch) | |
tree | 342765e41aed9f42a0ad9255bed8ec3c73c7cdb5 /drivers/block | |
parent | 5f9bbea02f06110ec5cf95a3327019b3194b2d80 (diff) |
null_blk: Do not set disk->nr_zones
In null_register_zoned_dev(), there is no need to set disk->nr_zones as
the now uncoditional call to blk_revalidate_disk_zones() will do that.
So remove the assignment using bdev_nr_zones().
Signed-off-by: Damien Le Moal <dlemoal@kernel.org>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Johannes Thumshirn <johannes.thumshirn@wdc.com>
Link: https://lore.kernel.org/r/20240621031506.759397-2-dlemoal@kernel.org
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'drivers/block')
-rw-r--r-- | drivers/block/null_blk/zoned.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/drivers/block/null_blk/zoned.c b/drivers/block/null_blk/zoned.c index b42c00f13132..9f7151ad93cf 100644 --- a/drivers/block/null_blk/zoned.c +++ b/drivers/block/null_blk/zoned.c @@ -171,8 +171,6 @@ int null_register_zoned_dev(struct nullb *nullb) struct request_queue *q = nullb->q; struct gendisk *disk = nullb->disk; - disk->nr_zones = bdev_nr_zones(disk->part0); - pr_info("%s: using %s zone append\n", disk->disk_name, queue_emulates_zone_append(q) ? "emulated" : "native"); |