From: Xiaoyao Li <[email protected]> Since commit 7429aebe1cff ("vfio/migration: Remove VFIO migration protocol v1"), vfio_region_unmap() lost all its callers.
Remove unused vfio_region_unmap(). Signed-off-by: Xiaoyao Li <[email protected]> Reviewed-by: Cédric Le Goater <[email protected]> Link: https://lore.kernel.org/qemu-devel/[email protected] Signed-off-by: Cédric Le Goater <[email protected]> --- hw/vfio/vfio-region.h | 1 - hw/vfio/region.c | 15 --------------- 2 files changed, 16 deletions(-) diff --git a/hw/vfio/vfio-region.h b/hw/vfio/vfio-region.h index 9b21d4ee5ba16f8c05be83c75d1c7a6ad4cf8370..58b236f1133e7e7f6c99b440d9125e96e6529085 100644 --- a/hw/vfio/vfio-region.h +++ b/hw/vfio/vfio-region.h @@ -41,7 +41,6 @@ int vfio_region_setup(Object *obj, VFIODevice *vbasedev, VFIORegion *region, int index, const char *name, Error **errp); int vfio_region_mmap(VFIORegion *region); void vfio_region_mmaps_set_enabled(VFIORegion *region, bool enabled); -void vfio_region_unmap(VFIORegion *region); void vfio_region_exit(VFIORegion *region); void vfio_region_finalize(VFIORegion *region); diff --git a/hw/vfio/region.c b/hw/vfio/region.c index 0342ca712acd0ad846685115c29432c15aa966a0..dbde3391802691888ca31d5e329aba5ba680feb4 100644 --- a/hw/vfio/region.c +++ b/hw/vfio/region.c @@ -468,21 +468,6 @@ no_mmap: return ret; } -void vfio_region_unmap(VFIORegion *region) -{ - int i; - - if (!region->mem) { - return; - } - - for (i = 0; i < region->nr_mmaps; i++) { - if (region->mmaps[i].mmap) { - vfio_subregion_unmap(region, i); - } - } -} - void vfio_region_exit(VFIORegion *region) { int i; -- 2.54.0
