Re: [Xen-devel] [PATCH 5/9] x86/vvmx: Make updating shadow EPTP value more efficient

2017-10-02 Thread Sergey Dyasli
On Fri, 2017-09-29 at 16:56 +0100, Andrew Cooper wrote: > On 29/09/17 16:01, George Dunlap wrote: > > @@ -4203,13 +4197,17 @@ static void lbr_fixup(void) > > bdw_erratum_bdf14_fixup(); > > } > > > > -void vmx_vmenter_helper(const struct cpu_user_regs *regs) > > +int

Re: [Xen-devel] [PATCH 5/9] x86/vvmx: Make updating shadow EPTP value more efficient

2017-09-29 Thread Andrew Cooper
On 29/09/17 16:01, George Dunlap wrote: > @@ -4203,13 +4197,17 @@ static void lbr_fixup(void) > bdw_erratum_bdf14_fixup(); > } > > -void vmx_vmenter_helper(const struct cpu_user_regs *regs) > +int vmx_vmenter_helper(const struct cpu_user_regs *regs) What are the semantics of this

[Xen-devel] [PATCH 5/9] x86/vvmx: Make updating shadow EPTP value more efficient

2017-09-29 Thread George Dunlap
At the moment, the shadow EPTP value is written unconditionally in ept_handle_violation(). Instead, write the value on vmentry to the guest; but only write it if the value needs updating. To detect this, add a flag to the nestedvcpu struct, stale_np2m, to indicate when such an action is