diff options
author | Lu Baolu <baolu.lu@linux.intel.com> | 2019-06-11 20:28:46 -0400 |
---|---|---|
committer | Joerg Roedel <jroedel@suse.de> | 2019-06-12 04:36:59 -0400 |
commit | c57b260a7d7d60dfbcf794dd9836c1d9fdbf5434 (patch) | |
tree | 7d30373dd97e393c3565e27f010138c6c3960517 /drivers/iommu/intel-iommu.c | |
parent | f4c63ea91c6f6d9a1a3062071ff6cc4910ebb8a9 (diff) |
iommu/vt-d: Set domain type for a private domain
Otherwise, domain_get_iommu() will be broken.
Fixes: 942067f1b6b97 ("iommu/vt-d: Identify default domains replaced with private")
Signed-off-by: Lu Baolu <baolu.lu@linux.intel.com>
Signed-off-by: Joerg Roedel <jroedel@suse.de>
Diffstat (limited to 'drivers/iommu/intel-iommu.c')
-rw-r--r-- | drivers/iommu/intel-iommu.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/iommu/intel-iommu.c b/drivers/iommu/intel-iommu.c index 60ec58bf6701..862c978d3eb4 100644 --- a/drivers/iommu/intel-iommu.c +++ b/drivers/iommu/intel-iommu.c | |||
@@ -3494,6 +3494,8 @@ static struct dmar_domain *get_private_domain_for_dev(struct device *dev) | |||
3494 | out: | 3494 | out: |
3495 | if (!domain) | 3495 | if (!domain) |
3496 | dev_err(dev, "Allocating domain failed\n"); | 3496 | dev_err(dev, "Allocating domain failed\n"); |
3497 | else | ||
3498 | domain->domain.type = IOMMU_DOMAIN_DMA; | ||
3497 | 3499 | ||
3498 | return domain; | 3500 | return domain; |
3499 | } | 3501 | } |