Lines Matching full:md
19 static int dm_blk_do_report_zones(struct mapped_device *md, struct dm_table *t, in dm_blk_do_report_zones() argument
23 struct gendisk *disk = md->disk; in dm_blk_do_report_zones()
57 struct mapped_device *md = disk->private_data; in dm_blk_report_zones() local
59 struct dm_table *zone_revalidate_map = md->zone_revalidate_map; in dm_blk_report_zones()
63 if (!zone_revalidate_map || md->revalidate_map_task != current) { in dm_blk_report_zones()
69 if (dm_suspended_md(md)) in dm_blk_report_zones()
72 map = dm_get_live_table(md, &srcu_idx); in dm_blk_report_zones()
80 ret = dm_blk_do_report_zones(md, map, sector, nr_zones, cb, in dm_blk_report_zones()
84 dm_put_live_table(md, srcu_idx); in dm_blk_report_zones()
137 bool dm_is_zone_write(struct mapped_device *md, struct bio *bio) in dm_is_zone_write() argument
139 struct request_queue *q = md->queue; in dm_is_zone_write()
161 struct mapped_device *md = t->md; in dm_revalidate_zones() local
162 struct gendisk *disk = md->disk; in dm_revalidate_zones()
173 if (dm_has_zone_plugs(md)) in dm_revalidate_zones()
184 md->zone_revalidate_map = t; in dm_revalidate_zones()
185 md->revalidate_map_task = current; in dm_revalidate_zones()
187 md->revalidate_map_task = NULL; in dm_revalidate_zones()
188 md->zone_revalidate_map = NULL; in dm_revalidate_zones()
196 md->nr_zones = disk->nr_zones; in dm_revalidate_zones()
341 struct mapped_device *md = t->md; in dm_set_zones_restrictions() local
342 struct gendisk *disk = md->disk; in dm_set_zones_restrictions()
400 if (get_capacity(disk) && dm_has_zone_plugs(t->md)) { in dm_set_zones_restrictions()
436 struct mapped_device *md = t->md; in dm_finalize_zone_settings() local
440 clear_bit(DMF_EMULATE_ZONE_APPEND, &md->flags); in dm_finalize_zone_settings()
442 set_bit(DMF_EMULATE_ZONE_APPEND, &md->flags); in dm_finalize_zone_settings()
444 clear_bit(DMF_EMULATE_ZONE_APPEND, &md->flags); in dm_finalize_zone_settings()
445 md->nr_zones = 0; in dm_finalize_zone_settings()
446 md->disk->nr_zones = 0; in dm_finalize_zone_settings()
456 struct mapped_device *md = io->md; in dm_zone_endio() local
457 struct gendisk *disk = md->disk; in dm_zone_endio()
491 int dm_zone_get_reset_bitmap(struct mapped_device *md, struct dm_table *t, in dm_zone_get_reset_bitmap() argument
497 ret = dm_blk_do_report_zones(md, t, sector, nr_zones, in dm_zone_get_reset_bitmap()
501 md->disk->disk_name); in dm_zone_get_reset_bitmap()