[Intel-gfx] [PATCH v14 24/26] vfio: Move the IOMMU_CAP_CACHE_COHERENCY check in __vfio_register_dev()
Jason Gunthorpe
jgg at nvidia.com
Fri Jul 14 15:14:59 UTC 2023
On Mon, Jul 10, 2023 at 07:59:26PM -0700, Yi Liu wrote:
> The IOMMU_CAP_CACHE_COHERENCY check only applies to the physical devices
> that are IOMMU-backed. But it is now in the group code. If want to compile
> vfio_group infrastructure out, this check needs to be moved out of the group
> code.
>
> Another reason for this change is to fail the device registration for the
> physical devices that do not have IOMMU if the group code is not compiled
> as the cdev interface does not support such devices.
>
> Suggested-by: Jason Gunthorpe <jgg at nvidia.com>
> Signed-off-by: Yi Liu <yi.l.liu at intel.com>
> ---
> drivers/vfio/group.c | 10 ----------
> drivers/vfio/vfio_main.c | 11 +++++++++++
> 2 files changed, 11 insertions(+), 10 deletions(-)
Reviewed-by: Jason Gunthorpe <jgg at nvidia.com>
Jason
More information about the Intel-gfx
mailing list