projects
/
xen.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8a02aa3
)
vtd: addr_to_dma_page_maddr() must release its lock.
author
Keir Fraser
<keir.fraser@citrix.com>
Thu, 29 May 2008 08:39:23 +0000
(09:39 +0100)
committer
Keir Fraser
<keir.fraser@citrix.com>
Thu, 29 May 2008 08:39:23 +0000
(09:39 +0100)
Signed-off-by: Xiaowei Yang <xiaowei.yang@intel.com>
xen/drivers/passthrough/vtd/iommu.c
patch
|
blob
|
history
diff --git
a/xen/drivers/passthrough/vtd/iommu.c
b/xen/drivers/passthrough/vtd/iommu.c
index 777739d49d2ff0e708956a3b6e47d63845ba4d22..bdd049ba4b17d628d96d5891b81f36ecde352a94 100644
(file)
--- a/
xen/drivers/passthrough/vtd/iommu.c
+++ b/
xen/drivers/passthrough/vtd/iommu.c
@@
-212,10
+212,10
@@
static u64 addr_to_dma_page_maddr(struct domain *domain, u64 addr, int alloc)
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 domain *domain, u64 addr, int alloc)
}
unmap_vtd_domain_page(parent);
+ out:
spin_unlock_irqrestore(&hd->mapping_lock, flags);
return pte_maddr;
}