[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-changelog] [xen-unstable] vtd: minor edge case memory leak



# HG changeset patch
# User Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1221474920 -3600
# Node ID 01fb29f7283247951bb822684febbf20ecbaed45
# Parent  c353f07bae84133a83ec1dbf54bc5f868fd45bb2
vtd: minor edge case memory leak

Fixes an (unlikely) memory leak where mapped VT-d root entries are not
unmapped on allocation failure code path.

Signed-off-by: Ross Philipson <ross.philipson@xxxxxxxxxx>
---
 xen/drivers/passthrough/vtd/iommu.c |    1 +
 1 files changed, 1 insertion(+)

diff -r c353f07bae84 -r 01fb29f72832 xen/drivers/passthrough/vtd/iommu.c
--- a/xen/drivers/passthrough/vtd/iommu.c       Mon Sep 15 11:34:42 2008 +0100
+++ b/xen/drivers/passthrough/vtd/iommu.c       Mon Sep 15 11:35:20 2008 +0100
@@ -152,6 +152,7 @@ static u64 bus_to_context_maddr(struct i
         maddr = alloc_pgtable_maddr();
         if ( maddr == 0 )
         {
+            unmap_vtd_domain_page(root_entries);
             spin_unlock_irqrestore(&iommu->lock, flags);
             return 0;
         }

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.