Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
iommu: Move bus setup to IOMMU device registration
Move the bus setup to iommu_device_register(). This should allow bus_iommu_probe() to be correctly replayed for multiple IOMMU instances, and leaves bus_set_iommu() as a glorified no-op to be cleaned up next. At this point we can also handle cleanup better than just rolling back the most-recently-touched bus upon failure - which may release devices owned by other already-registered instances, and still leave devices on other buses with dangling pointers to the failed instance. Now it's easy to clean up the exact footprint of a given instance, no more, no less. Tested-by: Marek Szyprowski <[email protected]> Reviewed-by: Krishna Reddy <[email protected]> Reviewed-by: Kevin Tian <[email protected]> Tested-by: Matthew Rosato <[email protected]> # s390 Tested-by: Niklas Schnelle <[email protected]> # s390 Signed-off-by: Robin Murphy <[email protected]> Link: https://lore.kernel.org/r/d342b6f27efb5ef3e93aacaa3012d25386d74866.1660572783.git.robin.murphy@arm.com Signed-off-by: Joerg Roedel <[email protected]>
- Loading branch information