Re: [PATCH v2 01/16] iommu: introduce bind_pasid_table API function

2017-10-11 Thread Jean-Philippe Brucker
On 10/10/17 22:42, Jacob Pan wrote: [...] >>> +/** >>> + * PASID table data used to bind guest PASID table to the host >>> IOMMU. This will >>> + * enable guest managed first level page tables. >>> + * @version: for future extensions and identification of the data >>> format >>> + * @bytes: size of

Re: [PATCH v2 01/16] iommu: introduce bind_pasid_table API function

2017-10-10 Thread Jacob Pan
On Tue, 10 Oct 2017 17:45:53 +0100 Jean-Philippe Brucker wrote: > On 06/10/17 00:03, Jacob Pan wrote: > > Virtual IOMMU was proposed to support Shared Virtual Memory (SVM) > > use in the guest: > > https://lists.gnu.org/archive/html/qemu-devel/2016-11/msg05311.html > > > > As part of the propose

Re: [PATCH v2 01/16] iommu: introduce bind_pasid_table API function

2017-10-10 Thread Jacob Pan
On Tue, 10 Oct 2017 15:14:33 +0200 Joerg Roedel wrote: > Hi Jacob, > > On Thu, Oct 05, 2017 at 04:03:29PM -0700, Jacob Pan wrote: > > +int iommu_unbind_pasid_table(struct iommu_domain *domain, struct > > device *dev) +{ > > + if (unlikely(!domain->ops->unbind_pasid_table)) > > + retu

Re: [PATCH v2 01/16] iommu: introduce bind_pasid_table API function

2017-10-10 Thread Jean-Philippe Brucker
On 06/10/17 00:03, Jacob Pan wrote: > Virtual IOMMU was proposed to support Shared Virtual Memory (SVM) > use in the guest: > https://lists.gnu.org/archive/html/qemu-devel/2016-11/msg05311.html > > As part of the proposed architecture, when an SVM capable PCI > device is assigned to a guest, neste

Re: [PATCH v2 01/16] iommu: introduce bind_pasid_table API function

2017-10-10 Thread Joerg Roedel
Hi Jacob, On Thu, Oct 05, 2017 at 04:03:29PM -0700, Jacob Pan wrote: > +int iommu_unbind_pasid_table(struct iommu_domain *domain, struct device *dev) > +{ > + if (unlikely(!domain->ops->unbind_pasid_table)) > + return -EINVAL; > + > + return domain->ops->unbind_pasid_table(doma

[PATCH v2 01/16] iommu: introduce bind_pasid_table API function

2017-10-05 Thread Jacob Pan
Virtual IOMMU was proposed to support Shared Virtual Memory (SVM) use in the guest: https://lists.gnu.org/archive/html/qemu-devel/2016-11/msg05311.html As part of the proposed architecture, when an SVM capable PCI device is assigned to a guest, nested mode is turned on. Guest owns the first level