On Fri, Mar 15, 2019 at 08:38:38AM -0600, Jan Beulich wrote: > >>> On 07.02.19 at 17:44, <wei.l...@citrix.com> wrote: > > --- a/xen/arch/x86/mm.c > > +++ b/xen/arch/x86/mm.c > > @@ -4752,13 +4752,13 @@ static l3_pgentry_t *virt_to_xen_l3e(unsigned long > > v) > > > > if ( !pl3e ) > > return NULL; > > - clear_page(pl3e); > > if ( locking ) > > spin_lock(&map_pgdir_lock); > > if ( !(l4e_get_flags(*pl4e) & _PAGE_PRESENT) ) > > { > > l4_pgentry_t l4e = l4e_from_paddr(__pa(pl3e), > > __PAGE_HYPERVISOR); > > > > + clear_page(pl3e); > > Is this really an optimization? You treat avoiding to clear the page > in a hopefully infrequent case of a race for holding the spin lock > for quite a bit longer.
I was actually two minded while writing this patch. It is difficult to prove one way or the other. To avoid distracting from the main issue at hand, dropping this patch is the best way forward. Wei. > > Jan > > _______________________________________________ Xen-devel mailing list Xen-devel@lists.xenproject.org https://lists.xenproject.org/mailman/listinfo/xen-devel