aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86/kernel/amd_iommu.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/x86/kernel/amd_iommu.c')
-rw-r--r--arch/x86/kernel/amd_iommu.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/arch/x86/kernel/amd_iommu.c b/arch/x86/kernel/amd_iommu.c
index 2c63d874813..8510e90ebfe 100644
--- a/arch/x86/kernel/amd_iommu.c
+++ b/arch/x86/kernel/amd_iommu.c
@@ -1779,8 +1779,10 @@ static void *alloc_coherent(struct device *dev, size_t size,
1779 *dma_addr = __map_single(dev, iommu, domain->priv, paddr, 1779 *dma_addr = __map_single(dev, iommu, domain->priv, paddr,
1780 size, DMA_BIDIRECTIONAL, true, dma_mask); 1780 size, DMA_BIDIRECTIONAL, true, dma_mask);
1781 1781
1782 if (*dma_addr == bad_dma_address) 1782 if (*dma_addr == bad_dma_address) {
1783 spin_unlock_irqrestore(&domain->lock, flags);
1783 goto out_free; 1784 goto out_free;
1785 }
1784 1786
1785 iommu_completion_wait(iommu); 1787 iommu_completion_wait(iommu);
1786 1788