iommu: Remove wrong default domain comments
These comments are wrong. request_default_domain_for_dev doesn't just handle direct mapped domains. Signed-off-by: Tom Murphy <murphyt7@tcd.ie> Signed-off-by: Joerg Roedel <jroedel@suse.de>
This commit is contained in:
parent
6b0c54e7f2
commit
d127bc9be8
|
@ -2200,7 +2200,6 @@ request_default_domain_for_dev(struct device *dev, unsigned long type)
|
||||||
|
|
||||||
mutex_lock(&group->mutex);
|
mutex_lock(&group->mutex);
|
||||||
|
|
||||||
/* Check if the default domain is already direct mapped */
|
|
||||||
ret = 0;
|
ret = 0;
|
||||||
if (group->default_domain && group->default_domain->type == type)
|
if (group->default_domain && group->default_domain->type == type)
|
||||||
goto out;
|
goto out;
|
||||||
|
@ -2210,7 +2209,6 @@ request_default_domain_for_dev(struct device *dev, unsigned long type)
|
||||||
if (iommu_group_device_count(group) != 1)
|
if (iommu_group_device_count(group) != 1)
|
||||||
goto out;
|
goto out;
|
||||||
|
|
||||||
/* Allocate a direct mapped domain */
|
|
||||||
ret = -ENOMEM;
|
ret = -ENOMEM;
|
||||||
domain = __iommu_domain_alloc(dev->bus, type);
|
domain = __iommu_domain_alloc(dev->bus, type);
|
||||||
if (!domain)
|
if (!domain)
|
||||||
|
@ -2225,7 +2223,7 @@ request_default_domain_for_dev(struct device *dev, unsigned long type)
|
||||||
|
|
||||||
iommu_group_create_direct_mappings(group, dev);
|
iommu_group_create_direct_mappings(group, dev);
|
||||||
|
|
||||||
/* Make the direct mapped domain the default for this group */
|
/* Make the domain the default for this group */
|
||||||
if (group->default_domain)
|
if (group->default_domain)
|
||||||
iommu_domain_free(group->default_domain);
|
iommu_domain_free(group->default_domain);
|
||||||
group->default_domain = domain;
|
group->default_domain = domain;
|
||||||
|
|
Loading…
Reference in New Issue