Re: [PATCH v14 10/22] vfio iommu type1: Add support for mediated devices

2016-11-16 Thread Kirti Wankhede
VFIO IOMMU drivers are designed for the devices which are IOMMU capable. Mediated device only uses IOMMU APIs, the underlying hardware can be managed by an IOMMU domain. Aim of this change is: - To use most of the code of TYPE1 IOMMU driver for mediated devices - To support direct assigned device

Re: [PATCH v14 10/22] vfio iommu type1: Add support for mediated devices

2016-11-16 Thread Kirti Wankhede
On 11/17/2016 5:27 AM, Alex Williamson wrote: > On Thu, 17 Nov 2016 02:16:22 +0530 > Kirti Wankhede wrote: >> @@ -931,6 +1344,24 @@ static void vfio_iommu_type1_detach_group(void >> *iommu_data, >> >> mutex_lock(&iommu->lock); >> >> +if (iommu->external_domain) { >> +gr

Re: [PATCH v14 10/22] vfio iommu type1: Add support for mediated devices

2016-11-16 Thread Alex Williamson
On Thu, 17 Nov 2016 02:16:22 +0530 Kirti Wankhede wrote: > @@ -931,6 +1344,24 @@ static void vfio_iommu_type1_detach_group(void > *iommu_data, > > mutex_lock(&iommu->lock); > > + if (iommu->external_domain) { > + group = find_iommu_group(iommu->external_domain, iommu_gro

[PATCH v14 10/22] vfio iommu type1: Add support for mediated devices

2016-11-16 Thread Kirti Wankhede
VFIO IOMMU drivers are designed for the devices which are IOMMU capable. Mediated device only uses IOMMU APIs, the underlying hardware can be managed by an IOMMU domain. Aim of this change is: - To use most of the code of TYPE1 IOMMU driver for mediated devices - To support direct assigned device