[PATCH v5 00/27] Update SMMUv3 to the modern iommu API (part 2/3)
Jason Gunthorpe
jgg at nvidia.com
Mon Mar 25 09:47:17 PDT 2024
On Mon, Mar 25, 2024 at 11:22:19AM +0000, Mostafa Saleh wrote:
> > I think that is probably because you are testing with "nested-smmuv3". This
> > series not yet fully enable that. For that, I think you are missing few patches
> > from Nicolin's iommufd branch,
> > https://github.com/nicolinc/iommufd/commits/wip/iommufd_nesting-03112024/
>
> I see, thanks for clarifying. I think we shouldn't still crash the
> kernel, but that's a problem for part 3.
Yeah, definately. Part 3 needs to include the invalidation bits too, I
haven't integrated them from Nicolin.
I'll send a patch like this for iommufd to stop the oops:
@@ -236,7 +236,8 @@ iommufd_hwpt_nested_alloc(struct iommufd_ctx *ictx,
}
hwpt->domain->owner = ops;
- if (WARN_ON_ONCE(hwpt->domain->type != IOMMU_DOMAIN_NESTED)) {
+ if (WARN_ON_ONCE(hwpt->domain->type != IOMMU_DOMAIN_NESTED ||
+ !hwpt->domain->ops->cache_invalidate_user)) {
rc = -EINVAL;
goto out_abort;
}
Jason
More information about the linux-arm-kernel
mailing list