Commit dcde1c4a authored by Robin Murphy's avatar Robin Murphy Committed by Joerg Roedel
Browse files

iommu/rockchip: Retire global dma_dev workaround



The global dma_dev trick was mostly because the old domain_alloc op
provided no context, so no way to know which IOMMU was to own the
pagetable, or if a suitable one even existed at all. In the new
multi-instance world with domain_alloc_paging this is no longer a
concern - now we know that the given device must be associated with a
valid IOMMU instance which provided the op to call in the first place,
and therefore that instance can and should be the pagetable owner. To
avoid worrying about the lifetime and stability of the rk_domain->iommus
list, and keep the lookups simple and efficient, we'll still stash a
dma_dev pointer, but now it's accurately per-domain.

Signed-off-by: default avatarRobin Murphy <robin.murphy@arm.com>
Tested-by: default avatarQuentin Schulz <quentin.schulz@cherry.de>
Tested-by: default avatarDang Huynh <danct12@riseup.net>
Reviewed-by: default avatarNicolas Frattaroli <nicolas.frattaroli@collabora.com>
Tested-by: default avatarNicolas Frattaroli <nicolas.frattaroli@collabora.com>
Link: https://lore.kernel.org/r/25dc948a7d35c8142c5719ac22bc523f8524d006.1741886382.git.robin.murphy@arm.com


Signed-off-by: default avatarJoerg Roedel <jroedel@suse.de>
parent f90aa59e
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment