]> asedeno.scripts.mit.edu Git - linux.git/commit
iommu/vt-d: Fix a potential memory leak
authorLu Baolu <baolu.lu@linux.intel.com>
Sat, 24 Feb 2018 05:42:27 +0000 (13:42 +0800)
committerJoerg Roedel <jroedel@suse.de>
Thu, 15 Mar 2018 14:15:22 +0000 (15:15 +0100)
commitbbe4b3af9d9e3172fb9aa1f8dcdfaedcb381fc64
tree64909a7dbabe5a93bc19678017ac27913b9d1652
parentb1d03c1d12abbfa7de127772f281b309cf1650c3
iommu/vt-d: Fix a potential memory leak

A memory block was allocated in intel_svm_bind_mm() but never freed
in a failure path. This patch fixes this by free it to avoid memory
leakage.

Cc: Ashok Raj <ashok.raj@intel.com>
Cc: Jacob Pan <jacob.jun.pan@linux.intel.com>
Cc: <stable@vger.kernel.org> # v4.4+
Signed-off-by: Lu Baolu <baolu.lu@linux.intel.com>
Fixes: 2f26e0a9c9860 ('iommu/vt-d: Add basic SVM PASID support')
Signed-off-by: Joerg Roedel <jroedel@suse.de>
drivers/iommu/intel-svm.c