]> Git Repo - J-linux.git/commitdiff
ARM: 9418/1: dma-mapping: Use iommu_paging_domain_alloc()
authorJason Gunthorpe <[email protected]>
Wed, 4 Sep 2024 12:40:10 +0000 (13:40 +0100)
committerRussell King (Oracle) <[email protected]>
Wed, 4 Sep 2024 14:02:07 +0000 (15:02 +0100)
Since arm_iommu_create_mapping() now accepts the device, let's replace
iommu_domain_alloc() with iommu_paging_domain_alloc() to retire the former.

Signed-off-by: Lu Baolu <[email protected]>
Reviewed-by: Jason Gunthorpe <[email protected]>
Reviewed-by: Vasant Hegde <[email protected]>
Acked-by: Michael S. Tsirkin <[email protected]>
Acked-by: Jeff Johnson <[email protected]>
Signed-off-by: Jason Gunthorpe <[email protected]>
Signed-off-by: Russell King (Oracle) <[email protected]>
arch/arm/mm/dma-mapping.c

index 52f9c56cc3cbbe714cece2775b210c81ff88d294..88c2d68a69c9ee9b43d2a916444b9b6eaaf601d7 100644 (file)
@@ -1585,9 +1585,11 @@ arm_iommu_create_mapping(struct device *dev, dma_addr_t base, u64 size)
 
        spin_lock_init(&mapping->lock);
 
-       mapping->domain = iommu_domain_alloc(dev->bus);
-       if (!mapping->domain)
+       mapping->domain = iommu_paging_domain_alloc(dev);
+       if (IS_ERR(mapping->domain)) {
+               err = PTR_ERR(mapping->domain);
                goto err4;
+       }
 
        kref_init(&mapping->kref);
        return mapping;
This page took 0.273976 seconds and 4 git commands to generate.