On 15/08/18 16:10, Jan Beulich wrote:
>>>> On 15.08.18 at 15:17, <andrew.coop...@citrix.com> wrote:
>> 2) 32bit PV guests which use writeable pagetable support will
>> automatically get shadowed when the clear the lower half.
> 
> ... of a page table entry.
> 
>>  Ideally, such
>> guests should be modified to use hypercalls rather than the ptwr
>> infrastructure (as its more efficient to begin with), but we can
>> probably work around this in Xen by emulating the next few instructions
>> until we have a complete PTE (same as the shadow code).
> 
> Provided the intervening insns are simple enough. I've looked into
> current Linux pv-ops code the other day, and afaict it's already
> using mmu-op or cmpxchg8b, but not two separate mov-s. But
> of course I've looked at the general routines only, not at things
> perhaps hidden in special cases, or in init-only code.

Look at xen_pte_clear(). Inside irq handling it will use (PAE case):

static inline void native_pte_clear(struct mm_struct *mm, unsigned long
addr,
                                    pte_t *ptep)
{
        ptep->pte_low = 0;
        smp_wmb();
        ptep->pte_high = 0;
}


Juergen

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

Reply via email to