Re: [PATCH v2 3/7] iommu: Make iommu_dma_prepare_msi() into a generic operation
From: Jason Gunthorpe
Date: Fri Feb 21 2025 - 11:50:32 EST
On Fri, Feb 21, 2025 at 03:39:45PM +0000, Robin Murphy wrote:
> Yuck. Realistically we are going to have no more than two different
> implementations of this; a fiddly callback interface seems overkill. All we
> should need in the domain is a simple indicator of *which* MSI translation
> scheme is in use (if it can't be squeezed into the domain type itself), then
> iommu_dma_prepare_msi() can simply dispatch between iommu-dma and IOMMUFD
> based on that, and then it's easy to solve all the other fragility issues
> too.
That would make module dependency problems, we have so far avoided
having the core kernel hard depend on iommufd.
Jason