Re: [PATCH v4 03/26] iommu: Add a page fault handler

2020-02-28 Thread Jean-Philippe Brucker
On Wed, Feb 26, 2020 at 01:59:33PM +, Jonathan Cameron wrote: > > +static int iopf_complete(struct device *dev, struct iopf_fault *iopf, > > +enum iommu_page_response_code status) > > This is called once per group. Should name reflect that? Ok [...] > > +/** > > + *

Re: [PATCH v4 03/26] iommu: Add a page fault handler

2020-02-26 Thread Jonathan Cameron
On Mon, 24 Feb 2020 19:23:38 +0100 Jean-Philippe Brucker wrote: > From: Jean-Philippe Brucker > > Some systems allow devices to handle I/O Page Faults in the core mm. For > example systems implementing the PCI PRI extension or Arm SMMU stall > model. Infrastructure for reporting these

Re: [PATCH v4 03/26] iommu: Add a page fault handler

2020-02-25 Thread Xu Zaibo
Hi, On 2020/2/25 17:25, Jean-Philippe Brucker wrote: Hi Zaibo, On Tue, Feb 25, 2020 at 11:30:05AM +0800, Xu Zaibo wrote: +struct iopf_queue * +iopf_queue_alloc(const char *name, iopf_queue_flush_t flush, void *cookie) +{ + struct iopf_queue *queue; + + queue =

Re: [PATCH v4 03/26] iommu: Add a page fault handler

2020-02-25 Thread Jean-Philippe Brucker
Hi Zaibo, On Tue, Feb 25, 2020 at 11:30:05AM +0800, Xu Zaibo wrote: > > +struct iopf_queue * > > +iopf_queue_alloc(const char *name, iopf_queue_flush_t flush, void *cookie) > > +{ > > + struct iopf_queue *queue; > > + > > + queue = kzalloc(sizeof(*queue), GFP_KERNEL); > > + if (!queue) > >

Re: [PATCH v4 03/26] iommu: Add a page fault handler

2020-02-24 Thread Xu Zaibo
Hi, On 2020/2/25 2:23, Jean-Philippe Brucker wrote: From: Jean-Philippe Brucker Some systems allow devices to handle I/O Page Faults in the core mm. For example systems implementing the PCI PRI extension or Arm SMMU stall model. Infrastructure for reporting these recoverable page faults was

[PATCH v4 03/26] iommu: Add a page fault handler

2020-02-24 Thread Jean-Philippe Brucker
From: Jean-Philippe Brucker Some systems allow devices to handle I/O Page Faults in the core mm. For example systems implementing the PCI PRI extension or Arm SMMU stall model. Infrastructure for reporting these recoverable page faults was recently added to the IOMMU core. Add a page fault