Re: [PATCH v3 07/11] iommu: Prepare for separating SVA and IOPF

Jason Gunthorpe
2023-08-21T17:08:00Z

On Fri, Aug 18, 2023 at 07:40:43AM +0800, Lu Baolu wrote:
> Move iopf_group data structure to iommu.h. This is being done to make it
> a minimal set of faults that a domain's page fault handler should handle.
>
> Add two new helpers for the domain's page fault handler:
> - iopf_free_group: free a fault group after all faults in the group are
> handled.
> - iopf_queue_work: queue a given work item for a fault group.
>
> This will simplify the sequential patches.
>
> Signed-off-by: Lu Baolu <baolu.lu@linux.intel.com>
> ---
> include/linux/iommu.h | 12 ++++++++++
> drivers/iommu/io-pgfault.c | 49 ++++++++++++++++++++++----------------
> 2 files changed, 41 insertions(+), 20 deletions(-)

Reviewed-by: Jason Gunthorpe <jgg@nvidia.com>

Jason