RE: [PATCH v7 11/22] vfio: Make vfio_device_first_open() to accept NULL iommufd for noiommu

Tian, Kevin
2023-03-17T01:45:12Z

> From: Liu, Yi L <yi.l.liu@intel.com>
> Sent: Thursday, March 16, 2023 8:55 PM
>
> vfio_device_first_open() requires the caller to provide either a valid
> iommufd (the group path in iommufd compat mode) or a valid container
> (the group path in legacy container mode). As preparation for noiommu
> support in device cdev path it's extended to allow both being NULL. The
> caller is expected to verify noiommu permission before passing NULL
> to this function.
>
> Signed-off-by: Yi Liu <yi.l.liu@intel.com>