[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH 03/17] vmx: nest: wrapper for control update



On Thu, 2010-05-20 at 17:34 +0800, Tim Deegan wrote:
> At 10:41 +0100 on 22 Apr (1271932875), Qing He wrote:
> > In nested virtualization, the L0 controls may not be the same
> > with controls in physical VMCS.
> > Explict maintain guest controls in variables and use wrappers
> > for control update, do not rely on physical control value.
> > 
> > Signed-off-by: Qing He <qing.he@xxxxxxxxx>
> 
> > diff -r fe49b7452637 -r a0bbec37b529 xen/arch/x86/hvm/vmx/vmcs.c
> > --- a/xen/arch/x86/hvm/vmx/vmcs.c       Thu Apr 22 21:49:38 2010 +0800
> > +++ b/xen/arch/x86/hvm/vmx/vmcs.c       Thu Apr 22 21:49:38 2010 +0800
> > @@ -737,10 +737,10 @@
> >      __vmwrite(VMCS_LINK_POINTER_HIGH, ~0UL);
> >  #endif
> > 
> > -    __vmwrite(EXCEPTION_BITMAP,
> > -              HVM_TRAP_MASK
> > +    v->arch.hvm_vmx.exception_bitmap = HVM_TRAP_MASK
> >                | (paging_mode_hap(d) ? 0 : (1U << TRAP_page_fault))
> > -              | (1U << TRAP_no_device));
> > +              | (1U << TRAP_no_device);
> > +    __vmwrite(EXCEPTION_BITMAP, v->arch.hvm_vmx.exception_bitmap);
> 
> Shouldn't this use the new vmx_update_exception_bitmap()?

I left it unchanged because it's in vmcs.c. To me, vmx.c is on top of
vmcs.c and I feel against inter-dependeny.

Anyway this feeling is not strong. And I'm fine with using
vmx_update_exception_bitmap here since inter-dependency is already
the case.

Thanks,
Qing
> 
> Cheers,
> 
> Tim.
> 
> -- 
> Tim Deegan <Tim.Deegan@xxxxxxxxxx>
> Principal Software Engineer, XenServer Engineering
> Citrix Systems UK Ltd.  (Company #02937203, SL9 0BG)

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.