]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
dm: remove useless md->nr_zones variable
authorBenjamin Marzinski <bmarzins@redhat.com>
Thu, 9 Oct 2025 03:24:11 +0000 (23:24 -0400)
committerMikulas Patocka <mpatocka@redhat.com>
Mon, 20 Oct 2025 13:21:56 +0000 (15:21 +0200)
md->nr_zones is no longer used for anything. Remove it.

Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
Reviewed-by: Damien Le Moal <dlemoal@kernel.org>
Signed-off-by: Mikulas Patocka <mpatocka@redhat.com>
drivers/md/dm-core.h
drivers/md/dm-zone.c

index a3c9f74fe2dc47f537aa3bb69347f1b6e4f0676a..1cda8618d74d2c2c9ce6023f6ae95d978add42c0 100644 (file)
@@ -139,7 +139,6 @@ struct mapped_device {
        struct srcu_struct io_barrier;
 
 #ifdef CONFIG_BLK_DEV_ZONED
-       unsigned int nr_zones;
        void *zone_revalidate_map;
        struct task_struct *revalidate_map_task;
 #endif
index 78e17dd4d01b8247dd11b1c6e14a09c7a8de28b0..cf4553e863f0448dd566ae8d042f59ebb1c43c81 100644 (file)
@@ -193,8 +193,6 @@ int dm_revalidate_zones(struct dm_table *t, struct request_queue *q)
                return ret;
        }
 
-       md->nr_zones = disk->nr_zones;
-
        return 0;
 }
 
@@ -442,7 +440,6 @@ void dm_finalize_zone_settings(struct dm_table *t, struct queue_limits *lim)
                        set_bit(DMF_EMULATE_ZONE_APPEND, &md->flags);
        } else {
                clear_bit(DMF_EMULATE_ZONE_APPEND, &md->flags);
-               md->nr_zones = 0;
                md->disk->nr_zones = 0;
        }
 }