Commit 3b498b66 authored by Robin Murphy's avatar Robin Murphy Committed by Alex Williamson

vfio: Use device_iommu_capable()

Use the new interface to check the capabilities for our device
specifically.
Reviewed-by: default avatarLu Baolu <baolu.lu@linux.intel.com>
Signed-off-by: default avatarRobin Murphy <robin.murphy@arm.com>
Reviewed-by: default avatarKevin Tian <kevin.tian@intel.com>
Reviewed-by: default avatarJason Gunthorpe <jgg@nvidia.com>
Link: https://lore.kernel.org/r/4ea5eb64246f1ee188d1a61c3e93b37756932eb7.1656092606.git.robin.murphy@arm.comSigned-off-by: default avatarAlex Williamson <alex.williamson@redhat.com>
parent eed20c78
......@@ -605,7 +605,7 @@ int vfio_register_group_dev(struct vfio_device *device)
* VFIO always sets IOMMU_CACHE because we offer no way for userspace to
* restore cache coherency.
*/
if (!iommu_capable(device->dev->bus, IOMMU_CAP_CACHE_COHERENCY))
if (!device_iommu_capable(device->dev, IOMMU_CAP_CACHE_COHERENCY))
return -EINVAL;
return __vfio_register_dev(device,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment