> From: Roger Pau Monne > Sent: Tuesday, December 08, 2015 12:48 AM > > Instead of choosing the interface to expose to guests based on the guest > type, do it based on whether the guest has an emulated local apic or not. > > Signed-off-by: Roger Pau Monné <roger....@citrix.com> > Signed-off-by: Boris Ostrovsky <boris.ostrov...@oracle.com> > Acked-by: Jan Beulich <jbeul...@suse.com> > Cc: Jan Beulich <jbeul...@suse.com> > Cc: Andrew Cooper <andrew.coop...@citrix.com> > ---
[...] > @@ -637,7 +638,7 @@ long do_xenpmu_op(unsigned int op, > XEN_GUEST_HANDLE_PARAM(xen_pmu_params_t) arg) > struct xen_pmu_data *xenpmu_data; > struct vpmu_struct *vpmu; > > - if ( !opt_vpmu_enabled ) > + if ( !opt_vpmu_enabled || has_vlapic(current->domain) ) > return -EOPNOTSUPP; !has_vlapic(current->domain)? [...] > diff --git a/xen/arch/x86/hvm/vmx/vmx.c b/xen/arch/x86/hvm/vmx/vmx.c > index 2581e97..06c12e1 100644 > --- a/xen/arch/x86/hvm/vmx/vmx.c > +++ b/xen/arch/x86/hvm/vmx/vmx.c > @@ -148,7 +148,7 @@ static int vmx_vcpu_initialise(struct vcpu *v) > } > > /* PVH's VPMU is initialized via hypercall */ > - if ( is_hvm_vcpu(v) ) > + if ( is_hvm_vcpu(v) && has_vlapic(v->domain) ) > vpmu_initialise(v); Is is_hvm_vcpu still required here? Thanks Kevin _______________________________________________ Xen-devel mailing list Xen-devel@lists.xen.org http://lists.xen.org/xen-devel