Re: [PATCH v8 07/10] iommufd: Fault-capable hwpt attach/detach/replace

2024-10-28 Thread Baolu Lu
On 2024/10/28 17:56, Zhangfei Gao wrote: On Sun, 27 Oct 2024 at 22:26, Baolu Lu wrote: Can you please make this change a formal patch by yourself? As I don't have hardware in hand, I'm not confident to accurately describe the requirement or verify the new version during the upstream process.

Re: [PATCH v8 07/10] iommufd: Fault-capable hwpt attach/detach/replace

2024-10-28 Thread Zhangfei Gao
On Sun, 27 Oct 2024 at 22:26, Baolu Lu wrote: > > Can you please make this change a formal patch by yourself? As I don't > have hardware in hand, I'm not confident to accurately describe the > requirement or verify the new version during the upstream process. > OK, how about this one Subject: [

Re: [PATCH v8 07/10] iommufd: Fault-capable hwpt attach/detach/replace

2024-10-27 Thread Baolu Lu
On 2024/10/27 22:12, Zhangfei Gao wrote: On Fri, 18 Oct 2024 at 10:45, Zhangfei Gao wrote: Hi, Baolu On Fri, 18 Oct 2024 at 09:58, Baolu Lu wrote: On 2024/10/17 21:08, Jason Gunthorpe wrote: On Thu, Oct 17, 2024 at 08:35:24PM +0800, Zhangfei Gao wrote: Yes, you are right I am using SRIOV

Re: [PATCH v8 07/10] iommufd: Fault-capable hwpt attach/detach/replace

2024-10-27 Thread Zhangfei Gao
Hi, Baolu On Fri, 18 Oct 2024 at 10:45, Zhangfei Gao wrote: > > Hi, Baolu > > On Fri, 18 Oct 2024 at 09:58, Baolu Lu wrote: > > > > On 2024/10/17 21:08, Jason Gunthorpe wrote: > > > On Thu, Oct 17, 2024 at 08:35:24PM +0800, Zhangfei Gao wrote: > > > > > >> Yes, you are right > > >> I am using

Re: [PATCH v8 07/10] iommufd: Fault-capable hwpt attach/detach/replace

2024-10-23 Thread Zhangfei Gao
On Tue, 22 Oct 2024 at 22:53, Jason Gunthorpe wrote: > > On Tue, Oct 22, 2024 at 10:30:10PM +0800, Zhangfei Gao wrote: > > On Fri, 18 Oct 2024 at 21:53, Jason Gunthorpe wrote: > > > > > > On Wed, Oct 16, 2024 at 12:25:03PM -0300, Jason Gunthorpe wrote: > > > > > > smmu-v3 needs some more fixing t

Re: [PATCH v8 07/10] iommufd: Fault-capable hwpt attach/detach/replace

2024-10-22 Thread Jason Gunthorpe
On Tue, Oct 22, 2024 at 10:30:10PM +0800, Zhangfei Gao wrote: > On Fri, 18 Oct 2024 at 21:53, Jason Gunthorpe wrote: > > > > On Wed, Oct 16, 2024 at 12:25:03PM -0300, Jason Gunthorpe wrote: > > > > > smmu-v3 needs some more fixing to move that > > > > > arm_smmu_master_enable_sva() logic into doma

Re: [PATCH v8 07/10] iommufd: Fault-capable hwpt attach/detach/replace

2024-10-22 Thread Zhangfei Gao
On Fri, 18 Oct 2024 at 21:53, Jason Gunthorpe wrote: > > On Wed, Oct 16, 2024 at 12:25:03PM -0300, Jason Gunthorpe wrote: > > > > smmu-v3 needs some more fixing to move that > > > > arm_smmu_master_enable_sva() logic into domain attachment. > > > > > > Will think about this, Thanks Jason > > > > C

Re: [PATCH v8 07/10] iommufd: Fault-capable hwpt attach/detach/replace

2024-10-18 Thread Jason Gunthorpe
On Fri, Oct 18, 2024 at 09:58:37AM +0800, Baolu Lu wrote: > On 2024/10/17 21:08, Jason Gunthorpe wrote: > > On Thu, Oct 17, 2024 at 08:35:24PM +0800, Zhangfei Gao wrote: > > > > > Yes, you are right > > > I am using SRIOV vf and stall feature, so is_virtfn == true > > > > > > Our ACC devices ar

Re: [PATCH v8 07/10] iommufd: Fault-capable hwpt attach/detach/replace

2024-10-18 Thread Jason Gunthorpe
On Wed, Oct 16, 2024 at 12:25:03PM -0300, Jason Gunthorpe wrote: > > > smmu-v3 needs some more fixing to move that > > > arm_smmu_master_enable_sva() logic into domain attachment. > > > > Will think about this, Thanks Jason > > Can you test it if a patch is made? Here it is: https://github.com/

Re: [PATCH v8 07/10] iommufd: Fault-capable hwpt attach/detach/replace

2024-10-17 Thread Zhangfei Gao
Hi, Baolu On Fri, 18 Oct 2024 at 09:58, Baolu Lu wrote: > > On 2024/10/17 21:08, Jason Gunthorpe wrote: > > On Thu, Oct 17, 2024 at 08:35:24PM +0800, Zhangfei Gao wrote: > > > >> Yes, you are right > >> I am using SRIOV vf and stall feature, so is_virtfn == true > >> > >> Our ACC devices are fa

Re: [PATCH v8 07/10] iommufd: Fault-capable hwpt attach/detach/replace

2024-10-17 Thread Baolu Lu
On 2024/10/17 21:08, Jason Gunthorpe wrote: On Thu, Oct 17, 2024 at 08:35:24PM +0800, Zhangfei Gao wrote: Yes, you are right I am using SRIOV vf and stall feature, so is_virtfn == true Our ACC devices are fake pci endpoint devices which supports stall, And they also supports sriov So I have

Re: [PATCH v8 07/10] iommufd: Fault-capable hwpt attach/detach/replace

2024-10-17 Thread Jason Gunthorpe
On Thu, Oct 17, 2024 at 08:35:24PM +0800, Zhangfei Gao wrote: > Yes, you are right > I am using SRIOV vf and stall feature, so is_virtfn == true > > Our ACC devices are fake pci endpoint devices which supports stall, > And they also supports sriov > > So I have to ignore the limitation. I see,

RE: [PATCH v8 07/10] iommufd: Fault-capable hwpt attach/detach/replace

2024-10-17 Thread Shameerali Kolothum Thodi
an > ; Joel Granados > ; io...@lists.linux.dev; > virtualization@lists.linux-foundation.org; linux-ker...@vger.kernel.org; > Shameerali Kolothum Thodi > Subject: Re: [PATCH v8 07/10] iommufd: Fault-capable hwpt > attach/detach/replace > > On Thu, 17 Oct 2024 at 20:05, Jason Gunthorpe

Re: [PATCH v8 07/10] iommufd: Fault-capable hwpt attach/detach/replace

2024-10-17 Thread Zhangfei Gao
On Thu, 17 Oct 2024 at 20:05, Jason Gunthorpe wrote: > > On Thu, Oct 17, 2024 at 09:44:18AM +0800, Zhangfei Gao wrote: > > On Wed, 16 Oct 2024 at 23:25, Jason Gunthorpe wrote: > > > > > > On Wed, Oct 16, 2024 at 09:58:36AM +0800, Zhangfei Gao wrote: > > > > On Tue, 15 Oct 2024 at 20:54, Jason Gun

Re: [PATCH v8 07/10] iommufd: Fault-capable hwpt attach/detach/replace

2024-10-17 Thread Jason Gunthorpe
On Thu, Oct 17, 2024 at 09:44:18AM +0800, Zhangfei Gao wrote: > On Wed, 16 Oct 2024 at 23:25, Jason Gunthorpe wrote: > > > > On Wed, Oct 16, 2024 at 09:58:36AM +0800, Zhangfei Gao wrote: > > > On Tue, 15 Oct 2024 at 20:54, Jason Gunthorpe wrote: > > > > > > > > On Tue, Oct 15, 2024 at 11:19:33AM

Re: [PATCH v8 07/10] iommufd: Fault-capable hwpt attach/detach/replace

2024-10-16 Thread Zhangfei Gao
On Wed, 16 Oct 2024 at 23:25, Jason Gunthorpe wrote: > > On Wed, Oct 16, 2024 at 09:58:36AM +0800, Zhangfei Gao wrote: > > On Tue, 15 Oct 2024 at 20:54, Jason Gunthorpe wrote: > > > > > > On Tue, Oct 15, 2024 at 11:19:33AM +0800, Zhangfei Gao wrote: > > > > > +static int iommufd_fault_iopf_enable

Re: [PATCH v8 07/10] iommufd: Fault-capable hwpt attach/detach/replace

2024-10-16 Thread Jason Gunthorpe
On Wed, Oct 16, 2024 at 09:58:36AM +0800, Zhangfei Gao wrote: > On Tue, 15 Oct 2024 at 20:54, Jason Gunthorpe wrote: > > > > On Tue, Oct 15, 2024 at 11:19:33AM +0800, Zhangfei Gao wrote: > > > > +static int iommufd_fault_iopf_enable(struct iommufd_device *idev) > > > > +{ > > > > + struct de

Re: [PATCH v8 07/10] iommufd: Fault-capable hwpt attach/detach/replace

2024-10-15 Thread Zhangfei Gao
On Tue, 15 Oct 2024 at 20:54, Jason Gunthorpe wrote: > > On Tue, Oct 15, 2024 at 11:19:33AM +0800, Zhangfei Gao wrote: > > > +static int iommufd_fault_iopf_enable(struct iommufd_device *idev) > > > +{ > > > + struct device *dev = idev->dev; > > > + int ret; > > > + > > > + /* > >

Re: [PATCH v8 07/10] iommufd: Fault-capable hwpt attach/detach/replace

2024-10-15 Thread Jason Gunthorpe
On Tue, Oct 15, 2024 at 11:19:33AM +0800, Zhangfei Gao wrote: > > +static int iommufd_fault_iopf_enable(struct iommufd_device *idev) > > +{ > > + struct device *dev = idev->dev; > > + int ret; > > + > > + /* > > +* Once we turn on PCI/PRI support for VF, the response failu

Re: [PATCH v8 07/10] iommufd: Fault-capable hwpt attach/detach/replace

2024-10-14 Thread Zhangfei Gao
Hi, Baolu On Tue, 2 Jul 2024 at 14:39, Lu Baolu wrote: > > Add iopf-capable hw page table attach/detach/replace helpers. The pointer > to iommufd_device is stored in the domain attachment handle, so that it > can be echo'ed back in the iopf_group. > > The iopf-capable hw page tables can only be a