[RPC]: iommu/dma: custom iommu_setup_dma_ops for secure iommu
From: Hsia-Jun Li
Date: Tue Mar 07 2023 - 05:53:45 EST
Hello All
If I want to implement a secure IOMMU. Is there any way other than hook
the iommu_setup_dma_ops() I still want to use the of(device tree) helper?
The secure IOMMU is a little different from the existing secure
attribute page table. The physical address and iova address not
available for the Linux environment(REE), even they are available, they
can't be configured to the secure device directly. So we don't need the
Linux kernel to allocate the iova address for us, means I need to
replace the current iommu_dma_map_sg() implementation.
Even sometimes it didn't do the iommu work, just allocate a secure
reference page id for a continuous memory. I think the iommu framework
is the most proper framework to implement this feature, it just fit the
steps of importing a buffer for the secure world.
Please give me some advice on this idea.
--
Hsia-Jun(Randy) Li