aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/iommu/dmar.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/iommu/dmar.c')
-rw-r--r--drivers/iommu/dmar.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/iommu/dmar.c b/drivers/iommu/dmar.c
index a88576d50740..8ccbd7023194 100644
--- a/drivers/iommu/dmar.c
+++ b/drivers/iommu/dmar.c
@@ -903,8 +903,10 @@ int __init detect_intel_iommu(void)
903 x86_init.iommu.iommu_init = intel_iommu_init; 903 x86_init.iommu.iommu_init = intel_iommu_init;
904#endif 904#endif
905 905
906 acpi_put_table(dmar_tbl); 906 if (dmar_tbl) {
907 dmar_tbl = NULL; 907 acpi_put_table(dmar_tbl);
908 dmar_tbl = NULL;
909 }
908 up_write(&dmar_global_lock); 910 up_write(&dmar_global_lock);
909 911
910 return ret ? 1 : -ENODEV; 912 return ret ? 1 : -ENODEV;