On Sat, Aug 12, 2023 at 09:41:50AM +0800, Baolu Lu wrote:
> > index e05c93b6c37fba..87aebba474e093 100644
> > --- a/include/linux/iommu.h
> > +++ b/include/linux/iommu.h
> > @@ -64,6 +64,7 @@ struct iommu_domain_geometry {
> > #define __IOMMU_DOMAIN_DMA_FQ (1U << 3) /* DMA-API uses flush que
On Sun, Aug 13, 2023 at 08:11:30PM +0800, Baolu Lu wrote:
> On 2023/8/12 19:28, Jason Gunthorpe wrote:
> > On Sat, Aug 12, 2023 at 09:36:33AM +0800, Baolu Lu wrote:
> > > > @@ -290,6 +295,7 @@ struct iommu_ops {
> > > > unsigned long pgsize_bitmap;
> > > > struct module *owner;
> >
On 2023/8/12 19:28, Jason Gunthorpe wrote:
On Sat, Aug 12, 2023 at 09:36:33AM +0800, Baolu Lu wrote:
@@ -290,6 +295,7 @@ struct iommu_ops {
unsigned long pgsize_bitmap;
struct module *owner;
struct iommu_domain *identity_domain;
+ struct iommu_domain *default_domain
On Sat, Aug 12, 2023 at 09:36:33AM +0800, Baolu Lu wrote:
> > @@ -290,6 +295,7 @@ struct iommu_ops {
> > unsigned long pgsize_bitmap;
> > struct module *owner;
> > struct iommu_domain *identity_domain;
> > + struct iommu_domain *default_domain;
>
> I am imaging whether we can merge a
On 2023/8/3 8:07, Jason Gunthorpe wrote:
@@ -1967,7 +1978,8 @@ void iommu_domain_free(struct iommu_domain *domain)
if (domain->type == IOMMU_DOMAIN_SVA)
mmdrop(domain->mm);
iommu_put_dma_cookie(domain);
- domain->ops->free(domain);
+ if (domain->ops->fr
On 2023/8/3 8:07, Jason Gunthorpe wrote:
This is used when the iommu driver is taking control of the dma_ops,
currently only on S390 and power spapr. It is designed to preserve the
original ops->detach_dev() semantic that these S390 was built around.
Provide an opaque domain type and a 'default_
This is used when the iommu driver is taking control of the dma_ops,
currently only on S390 and power spapr. It is designed to preserve the
original ops->detach_dev() semantic that these S390 was built around.
Provide an opaque domain type and a 'default_domain' ops value that allows
the driver to