|
|
|
|
|
|
|
|
|
|
xen-devel
[Xen-devel] [PATCH] further shrink the big-lock window
A few more adjustments to when the 'big' lock is taken/dropped. (The
WARN_ON used here depends on the previously sent patch adding common
support for this construct).
Also, fix a case where the foreign domain setting may not get properly
cleared at the end of a hypercall (in case of an early error).
Signed-off-by: Jan Beulich <jbeulich@xxxxxxxxxx>
Index: 2007-03-19/xen/arch/x86/mm.c
===================================================================
--- 2007-03-19.orig/xen/arch/x86/mm.c 2007-03-19 13:17:45.000000000 +0100
+++ 2007-03-19/xen/arch/x86/mm.c 2007-03-19 13:21:29.000000000 +0100
@@ -2431,13 +2431,13 @@ int do_mmu_update(
guest_handle_add_offset(ureqs, 1);
}
- domain_mmap_cache_destroy(&mapcache);
- domain_mmap_cache_destroy(&sh_mapcache);
-
process_deferred_ops();
UNLOCK_BIGLOCK(d);
+ domain_mmap_cache_destroy(&mapcache);
+ domain_mmap_cache_destroy(&sh_mapcache);
+
out:
/* Add incremental work we have done to the @done output parameter. */
if ( unlikely(!guest_handle_is_null(pdone)) )
@@ -2740,6 +2740,10 @@ int do_update_va_mapping(unsigned long v
guest_unmap_l1e(v, pl1e);
pl1e = NULL;
+ process_deferred_ops();
+
+ UNLOCK_BIGLOCK(d);
+
switch ( flags & UVMF_FLUSHTYPE_MASK )
{
case UVMF_TLB_FLUSH:
@@ -2785,9 +2789,7 @@ int do_update_va_mapping(unsigned long v
break;
}
- process_deferred_ops();
-
- UNLOCK_BIGLOCK(d);
+ WARN_ON(this_cpu(percpu_mm_info).deferred_ops);
return rc;
}
@@ -2806,6 +2808,8 @@ int do_update_va_mapping_otherdomain(uns
rc = do_update_va_mapping(va, val64, flags);
+ this_cpu(percpu_mm_info).foreign = NULL;
+
return rc;
}
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
|
<Prev in Thread] |
Current Thread |
[Next in Thread> |
- [Xen-devel] [PATCH] further shrink the big-lock window,
Jan Beulich <=
|
|
|
|
|