aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
Diffstat (limited to 'drivers')
-rw-r--r--drivers/pci/intel-iommu.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/drivers/pci/intel-iommu.c b/drivers/pci/intel-iommu.c
index 14308533b1cb..40ce5a03f18f 100644
--- a/drivers/pci/intel-iommu.c
+++ b/drivers/pci/intel-iommu.c
@@ -1673,7 +1673,16 @@ static int __domain_mapping(struct dmar_domain *domain, unsigned long iov_pfn,
1673 /* We don't need lock here, nobody else 1673 /* We don't need lock here, nobody else
1674 * touches the iova range 1674 * touches the iova range
1675 */ 1675 */
1676 BUG_ON(dma_pte_addr(pte)); 1676 if (unlikely(dma_pte_addr(pte))) {
1677 static int dumps = 5;
1678 printk(KERN_CRIT "ERROR: DMA PTE for vPFN 0x%lx already set (to %llx)\n",
1679 iov_pfn, pte->val);
1680 if (dumps) {
1681 dumps--;
1682 debug_dma_dump_mappings(NULL);
1683 }
1684 WARN_ON(1);
1685 }
1677 pte->val = pteval; 1686 pte->val = pteval;
1678 pte++; 1687 pte++;
1679 if (!nr_pages || 1688 if (!nr_pages ||