WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-changelog

[Xen-changelog] [xen-unstable] vtd: addr_to_dma_page_maddr() must releas

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] vtd: addr_to_dma_page_maddr() must release its lock.
From: Xen patchbot-unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Fri, 30 May 2008 11:00:29 -0700
Delivery-date: Fri, 30 May 2008 12:22:08 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1212050363 -3600
# Node ID 4505418b63933e4887c808e376985c2421d035e3
# Parent  f681c4de91fcfa90de2dbdc187eebd95d7927ee9
vtd: addr_to_dma_page_maddr() must release its lock.
Signed-off-by: Xiaowei Yang <xiaowei.yang@xxxxxxxxx>
---
 xen/drivers/passthrough/vtd/iommu.c |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diff -r f681c4de91fc -r 4505418b6393 xen/drivers/passthrough/vtd/iommu.c
--- a/xen/drivers/passthrough/vtd/iommu.c       Wed May 28 16:14:10 2008 +0100
+++ b/xen/drivers/passthrough/vtd/iommu.c       Thu May 29 09:39:23 2008 +0100
@@ -212,10 +212,10 @@ static u64 addr_to_dma_page_maddr(struct
     if ( hd->pgd_maddr == 0 )
     {
         if ( !alloc )
-            return 0;
+            goto out;
         hd->pgd_maddr = alloc_pgtable_maddr();
         if ( hd->pgd_maddr == 0 )
-            return 0;
+            goto out;
     }
 
     parent = (struct dma_pte *)map_vtd_domain_page(hd->pgd_maddr);
@@ -263,6 +263,7 @@ static u64 addr_to_dma_page_maddr(struct
     }
 
     unmap_vtd_domain_page(parent);
+ out:
     spin_unlock_irqrestore(&hd->mapping_lock, flags);
     return pte_maddr;
 }

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

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [xen-unstable] vtd: addr_to_dma_page_maddr() must release its lock., Xen patchbot-unstable <=