projects
/
firefly-linux-kernel-4.4.55.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5ced12a
)
iommu/vt-d: release invalidation queue when destroying IOMMU unit
author
Jiang Liu
<jiang.liu@linux.intel.com>
Mon, 6 Jan 2014 06:18:23 +0000
(14:18 +0800)
committer
Joerg Roedel
<joro@8bytes.org>
Thu, 9 Jan 2014 11:43:43 +0000
(12:43 +0100)
Release associated invalidation queue when destroying IOMMU unit
to avoid memory leak.
Signed-off-by: Jiang Liu <jiang.liu@linux.intel.com>
Signed-off-by: Joerg Roedel <joro@8bytes.org>
drivers/iommu/dmar.c
patch
|
blob
|
history
diff --git
a/drivers/iommu/dmar.c
b/drivers/iommu/dmar.c
index b0df78f9cd28b9868c328f1bb28ecef11c0e6129..726cfe296d9909197a44f3a622b5f9e6d2e435a9 100644
(file)
--- a/
drivers/iommu/dmar.c
+++ b/
drivers/iommu/dmar.c
@@
-737,6
+737,12
@@
static void free_iommu(struct intel_iommu *iommu)
destroy_irq(iommu->irq);
}
+ if (iommu->qi) {
+ free_page((unsigned long)iommu->qi->desc);
+ kfree(iommu->qi->desc_status);
+ kfree(iommu->qi);
+ }
+
if (iommu->reg)
unmap_iommu(iommu);