Skip to content

Commit 7b6dd84

Browse files
jgunthorpejoergroedel
authored andcommitted
iommu/vt-d: Update the definition of the blocking domain
The global static should pre-define the type and the NOP free function can be now left as NULL. Reviewed-by: Lu Baolu <baolu.lu@linux.intel.com> Signed-off-by: Jason Gunthorpe <jgg@nvidia.com> Reviewed-by: Kevin Tian <kevin.tian@intel.com> Acked-by: Sven Peter <sven@svenpeter.dev> Link: https://lore.kernel.org/r/2-v2-bff223cf6409+282-dart_paging_jgg@nvidia.com Signed-off-by: Joerg Roedel <jroedel@suse.de>
1 parent e5d8be7 commit 7b6dd84

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

drivers/iommu/intel/iommu.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4029,9 +4029,9 @@ static int blocking_domain_attach_dev(struct iommu_domain *domain,
40294029
}
40304030

40314031
static struct iommu_domain blocking_domain = {
4032+
.type = IOMMU_DOMAIN_BLOCKED,
40324033
.ops = &(const struct iommu_domain_ops) {
40334034
.attach_dev = blocking_domain_attach_dev,
4034-
.free = intel_iommu_domain_free
40354035
}
40364036
};
40374037

@@ -4076,7 +4076,7 @@ static struct iommu_domain *intel_iommu_domain_alloc(unsigned type)
40764076

40774077
static void intel_iommu_domain_free(struct iommu_domain *domain)
40784078
{
4079-
if (domain != &si_domain->domain && domain != &blocking_domain)
4079+
if (domain != &si_domain->domain)
40804080
domain_exit(to_dmar_domain(domain));
40814081
}
40824082

0 commit comments

Comments
 (0)