[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <YxH7rHvGfPuPgBg3@nvidia.com>
Date: Fri, 2 Sep 2022 09:48:44 -0300
From: Jason Gunthorpe <jgg@...dia.com>
To: Baolu Lu <baolu.lu@...ux.intel.com>
Cc: Joerg Roedel <joro@...tes.org>,
Christoph Hellwig <hch@...radead.org>,
Bjorn Helgaas <bhelgaas@...gle.com>,
Kevin Tian <kevin.tian@...el.com>,
Ashok Raj <ashok.raj@...el.com>, Will Deacon <will@...nel.org>,
Robin Murphy <robin.murphy@....com>,
Jean-Philippe Brucker <jean-philippe@...aro.com>,
Dave Jiang <dave.jiang@...el.com>,
Fenghua Yu <fenghua.yu@...el.com>,
Vinod Koul <vkoul@...nel.org>,
Eric Auger <eric.auger@...hat.com>,
Liu Yi L <yi.l.liu@...el.com>,
Jacob jun Pan <jacob.jun.pan@...el.com>,
Zhangfei Gao <zhangfei.gao@...aro.org>,
Zhu Tony <tony.zhu@...el.com>, iommu@...ts.linux.dev,
linux-pci@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v12 07/17] iommu: Try to allocate blocking domain when
probing device
On Thu, Sep 01, 2022 at 06:44:10PM +0800, Baolu Lu wrote:
> On 2022/8/31 22:10, Jason Gunthorpe wrote:
> > On Wed, Aug 31, 2022 at 09:49:44AM +0800, Baolu Lu wrote:
> > > > Maybe all of this is just the good reason to go to a simple
> > > > device->ops->remove_dev_pasid() callback and forget about blocking
> > > > domain here.
> > >
> > > Do you mean rolling back to what we did in v10?
> >
> > Yeah, but it shouldn't be a domain_op, removing a pasid is a device op
> >
> > Just
> >
> > remove_dev_pasid(struct device *dev, ioasid_t pasid)
>
> It's clear now. Thanks!
>
> How about below iommu_attach/detach_device_pasid() code?
I think this is probably the right thing
> By the way, how about naming it "block_dev_pasid(dev, pasid)"?
set/remove is a better pairing that set/block
Jason
Powered by blists - more mailing lists