diff options
author | Hannes Reinecke <hare@suse.de> | 2020-06-02 14:09:54 +0300 |
---|---|---|
committer | Mike Snitzer <snitzer@redhat.com> | 2020-06-05 21:59:53 +0300 |
commit | 69875d443bc3bb1b2e1f77fe3da5ad5c8c729aa2 (patch) | |
tree | e4cfef8b7e4e9b31ec026534e20692ec73103828 /drivers/md/dm-zoned.h | |
parent | 22c1ef66c4cbb82baf81a28abedfe8ad20ad9126 (diff) | |
download | linux-69875d443bc3bb1b2e1f77fe3da5ad5c8c729aa2.tar.xz |
dm zoned: select reclaim zone based on device index
per-device reclaim should select zones on that device only.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Reviewed-by: Damien Le Moal <damien.lemoal@wdc.com>
Signed-off-by: Mike Snitzer <snitzer@redhat.com>
Diffstat (limited to 'drivers/md/dm-zoned.h')
-rw-r--r-- | drivers/md/dm-zoned.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/md/dm-zoned.h b/drivers/md/dm-zoned.h index ec020bb1caf7..22f11440b423 100644 --- a/drivers/md/dm-zoned.h +++ b/drivers/md/dm-zoned.h @@ -61,6 +61,8 @@ struct dmz_dev { sector_t capacity; + unsigned int dev_idx; + unsigned int nr_zones; unsigned int zone_offset; @@ -243,7 +245,8 @@ static inline void dmz_activate_zone(struct dm_zone *zone) int dmz_lock_zone_reclaim(struct dm_zone *zone); void dmz_unlock_zone_reclaim(struct dm_zone *zone); -struct dm_zone *dmz_get_zone_for_reclaim(struct dmz_metadata *zmd, bool idle); +struct dm_zone *dmz_get_zone_for_reclaim(struct dmz_metadata *zmd, + unsigned int dev_idx, bool idle); struct dm_zone *dmz_get_chunk_mapping(struct dmz_metadata *zmd, unsigned int chunk, int op); |