diff options
author | Keir Fraser <keir.fraser@citrix.com> | 2010-05-13 08:55:41 +0100 |
---|---|---|
committer | Keir Fraser <keir.fraser@citrix.com> | 2010-05-13 08:55:41 +0100 |
commit | 2936184088f761697b7b899e1550fc75e6a9b4fe (patch) | |
tree | 501bbf5d5fe06458dfee635d3ac09363b58b966d /xen/include/asm-x86/hvm | |
parent | ced736bf180ffb22d42bdd0c82ce60eb8816ef4c (diff) | |
download | xen-2936184088f761697b7b899e1550fc75e6a9b4fe.tar.gz xen-2936184088f761697b7b899e1550fc75e6a9b4fe.tar.bz2 xen-2936184088f761697b7b899e1550fc75e6a9b4fe.zip |
VPMU: Make vpmu stucture visiable for both vmx and svm
Signed-off-by: Wei Wang <wei.wang2@amd.com>
Diffstat (limited to 'xen/include/asm-x86/hvm')
-rw-r--r-- | xen/include/asm-x86/hvm/vcpu.h | 3 | ||||
-rw-r--r-- | xen/include/asm-x86/hvm/vmx/vmcs.h | 3 | ||||
-rw-r--r-- | xen/include/asm-x86/hvm/vpmu.h | 4 |
3 files changed, 5 insertions, 5 deletions
diff --git a/xen/include/asm-x86/hvm/vcpu.h b/xen/include/asm-x86/hvm/vcpu.h index ed6b250ff9..150b30d32d 100644 --- a/xen/include/asm-x86/hvm/vcpu.h +++ b/xen/include/asm-x86/hvm/vcpu.h @@ -76,6 +76,9 @@ struct hvm_vcpu { u32 msr_tsc_aux; + /* VPMU */ + struct vpmu_struct vpmu; + union { struct arch_vmx_struct vmx; struct arch_svm_struct svm; diff --git a/xen/include/asm-x86/hvm/vmx/vmcs.h b/xen/include/asm-x86/hvm/vmx/vmcs.h index e8bd776641..29172e0d53 100644 --- a/xen/include/asm-x86/hvm/vmx/vmcs.h +++ b/xen/include/asm-x86/hvm/vmx/vmcs.h @@ -91,9 +91,6 @@ struct arch_vmx_struct { u32 exec_control; u32 secondary_exec_control; - /* PMU */ - struct vpmu_struct vpmu; - #ifdef __x86_64__ struct vmx_msr_state msr_state; unsigned long shadow_gs; diff --git a/xen/include/asm-x86/hvm/vpmu.h b/xen/include/asm-x86/hvm/vpmu.h index 5f5f2e344f..2baf8f29c7 100644 --- a/xen/include/asm-x86/hvm/vpmu.h +++ b/xen/include/asm-x86/hvm/vpmu.h @@ -23,9 +23,9 @@ #define __ASM_X86_HVM_VPMU_H_ #define msraddr_to_bitpos(x) (((x)&0xffff) + ((x)>>31)*0x2000) -#define vcpu_vpmu(vcpu) (&(vcpu)->arch.hvm_vcpu.u.vmx.vpmu) +#define vcpu_vpmu(vcpu) (&((vcpu)->arch.hvm_vcpu.vpmu)) #define vpmu_vcpu(vpmu) (container_of((vpmu), struct vcpu, \ - arch.hvm_vcpu.u.vmx.vpmu)) + arch.hvm_vcpu.vpmu)) #define vpmu_domain(vpmu) (vpmu_vcpu(vpmu)->domain) #define MSR_TYPE_COUNTER 0 |