aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2020-10-20 09:35:06 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2020-10-20 09:35:06 -0700
commit5c7e3f3f5cbc31118914ceee969154582ad3aa6b (patch)
treed40e726a59bbacb47e6e9d73fcd3a9337c74bc06
parent4a5bb973fa0353d25dbe854694c71bb58eb4cf78 (diff)
parent9def3b1a07c41e21c68a0eb353e3e569fdd1d2b1 (diff)
downloadext4-5c7e3f3f5cbc31118914ceee969154582ad3aa6b.tar.gz
Merge tag 'iommu-fix-v5.10' of git://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu
Pull iommu fix from Joerg Roedel: "Fix a build regression with !CONFIG_IOMMU_API" * tag 'iommu-fix-v5.10' of git://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu: iommu/vt-d: Don't dereference iommu_device if IOMMU_API is not built
-rw-r--r--drivers/iommu/intel/dmar.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/iommu/intel/dmar.c b/drivers/iommu/intel/dmar.c
index 2d70d56d8e0da7..404b40af31cb27 100644
--- a/drivers/iommu/intel/dmar.c
+++ b/drivers/iommu/intel/dmar.c
@@ -1136,7 +1136,7 @@ error:
static void free_iommu(struct intel_iommu *iommu)
{
- if (intel_iommu_enabled && iommu->iommu.ops) {
+ if (intel_iommu_enabled && !iommu->drhd->ignored) {
iommu_device_unregister(&iommu->iommu);
iommu_device_sysfs_remove(&iommu->iommu);
}