vfio: Introduce a vfio_uninit_group_dev() API call
authorMax Gurtovoy <mgurtovoy@nvidia.com>
Fri, 6 Aug 2021 01:18:59 +0000 (22:18 -0300)
committerAlex Williamson <alex.williamson@redhat.com>
Wed, 11 Aug 2021 15:50:10 +0000 (09:50 -0600)
commitae03c3771b8cbbed3802ad1153d896c32015c520
tree88b17c4754f6823d47dc2516ba43f8ff2ba38506
parentde5494af4815a4c9328536c72741229b7de88e7f
vfio: Introduce a vfio_uninit_group_dev() API call

This pairs with vfio_init_group_dev() and allows undoing any state that is
stored in the vfio_device unrelated to registration. Add appropriately
placed calls to all the drivers.

The following patch will use this to add pre-registration state for the
device set.

Signed-off-by: Max Gurtovoy <mgurtovoy@nvidia.com>
Reviewed-by: Cornelia Huck <cohuck@redhat.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
Link: https://lore.kernel.org/r/3-v4-9ea22c5e6afb+1adf-vfio_reflck_jgg@nvidia.com
Signed-off-by: Alex Williamson <alex.williamson@redhat.com>
Documentation/driver-api/vfio.rst
drivers/vfio/fsl-mc/vfio_fsl_mc.c
drivers/vfio/mdev/vfio_mdev.c
drivers/vfio/pci/vfio_pci.c
drivers/vfio/platform/vfio_platform_common.c
drivers/vfio/vfio.c
include/linux/vfio.h
samples/vfio-mdev/mbochs.c
samples/vfio-mdev/mdpy.c
samples/vfio-mdev/mtty.c