# HG changeset patch
# User Tim Deegan <Tim.Deegan@xxxxxxxxxx>
# Date 1307017012 -3600
# Node ID dd89c48f2ac5c55e8a46159390c2c2f83a7b7742
# Parent 51518c502d1b23a1cc4b325f81d17027a9d31a74
x86/mm/p2m: Remove recursive-locking code from set_shared_p2m_entry().
It should no longer be needed now that the shr_lock discipline is fixed.
Signed-off-by: Tim Deegan <Tim.Deegan@xxxxxxxxxx>
diff -r 51518c502d1b -r dd89c48f2ac5 xen/arch/x86/mm/p2m.c
--- a/xen/arch/x86/mm/p2m.c Thu Jun 02 13:16:52 2011 +0100
+++ b/xen/arch/x86/mm/p2m.c Thu Jun 02 13:16:52 2011 +0100
@@ -601,7 +601,6 @@ set_shared_p2m_entry(struct domain *d, u
{
struct p2m_domain *p2m = p2m_get_hostp2m(d);
int rc = 0;
- int need_lock = !p2m_locked_by_me(p2m);
p2m_type_t ot;
mfn_t omfn;
@@ -617,11 +616,9 @@ set_shared_p2m_entry(struct domain *d, u
set_gpfn_from_mfn(mfn_x(omfn), INVALID_M2P_ENTRY);
P2M_DEBUG("set shared %lx %lx\n", gfn, mfn_x(mfn));
- if ( need_lock )
- p2m_lock(p2m);
+ p2m_lock(p2m);
rc = set_p2m_entry(p2m, gfn, mfn, 0, p2m_ram_shared, p2m->default_access);
- if ( need_lock )
- p2m_unlock(p2m);
+ p2m_unlock(p2m);
if ( 0 == rc )
gdprintk(XENLOG_ERR,
"set_mmio_p2m_entry: set_p2m_entry failed! mfn=%08lx\n",
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
|