From: Brian Norris Date: Tue, 28 Mar 2017 18:31:02 +0000 (-0700) Subject: dm: move dm_table_destroy() to same header as dm_table_create() X-Git-Tag: Ubuntu-5.4-5.4.0-11.14~6075^2~21 X-Git-Url: https://git.proxmox.com/?a=commitdiff_plain;h=f6e7baadd96bd746d3fb584959d3f152189d05e1;p=mirror_ubuntu-focal-kernel.git dm: move dm_table_destroy() to same header as dm_table_create() If anyone is going to use dm_table_create(), they probably should be able to use dm_table_destroy() too. Move the dm_table_destroy() definition outside the private header, near dm_table_create() Signed-off-by: Brian Norris Signed-off-by: Mike Snitzer --- diff --git a/drivers/md/dm.h b/drivers/md/dm.h index 7c66c316add3..114a81b27c37 100644 --- a/drivers/md/dm.h +++ b/drivers/md/dm.h @@ -49,7 +49,6 @@ struct dm_md_mempools; /*----------------------------------------------------------------- * Internal table functions. *---------------------------------------------------------------*/ -void dm_table_destroy(struct dm_table *t); void dm_table_event_callback(struct dm_table *t, void (*fn)(void *), void *context); struct dm_target *dm_table_get_target(struct dm_table *t, unsigned int index); diff --git a/include/linux/device-mapper.h b/include/linux/device-mapper.h index 41ec228b02a6..9ba84532947d 100644 --- a/include/linux/device-mapper.h +++ b/include/linux/device-mapper.h @@ -459,6 +459,11 @@ void dm_table_set_type(struct dm_table *t, enum dm_queue_mode type); */ int dm_table_complete(struct dm_table *t); +/* + * Destroy the table when finished. + */ +void dm_table_destroy(struct dm_table *t); + /* * Target may require that it is never sent I/O larger than len. */