On Mon, Jul 10, 2023 at 07:59:25PM -0700, Yi Liu wrote:
> This adds ioctl for userspace to attach device cdev fd to and detach
> from IOAS/hw_pagetable managed by iommufd.
> 
>     VFIO_DEVICE_ATTACH_IOMMUFD_PT: attach vfio device to IOAS or hw_pagetable
>                                  managed by iommufd. Attach can be undo
>                                  by VFIO_DEVICE_DETACH_IOMMUFD_PT or device
>                                  fd close.
>     VFIO_DEVICE_DETACH_IOMMUFD_PT: detach vfio device from the current 
> attached
>                                  IOAS or hw_pagetable managed by iommufd.
> 
> Tested-by: Nicolin Chen <nicol...@nvidia.com>
> Tested-by: Matthew Rosato <mjros...@linux.ibm.com>
> Tested-by: Yanting Jiang <yanting.ji...@intel.com>
> Tested-by: Shameer Kolothum <shameerali.kolothum.th...@huawei.com>
> Tested-by: Terrence Xu <terrence...@intel.com>
> Signed-off-by: Yi Liu <yi.l....@intel.com>
> ---
>  drivers/vfio/device_cdev.c | 58 ++++++++++++++++++++++++++++++++++++++
>  drivers/vfio/vfio.h        |  5 ++++
>  drivers/vfio/vfio_main.c   | 15 +++++++++-
>  include/uapi/linux/vfio.h  | 44 +++++++++++++++++++++++++++++
>  4 files changed, 121 insertions(+), 1 deletion(-)

Reviewed-by: Jason Gunthorpe <j...@nvidia.com>

Jason

Reply via email to